diff --git a/plugins/kolab_notes/kolab_notes.php b/plugins/kolab_notes/kolab_notes.php index 86039ab2..ed50af7e 100644 --- a/plugins/kolab_notes/kolab_notes.php +++ b/plugins/kolab_notes/kolab_notes.php @@ -805,7 +805,7 @@ class kolab_notes extends rcube_plugin unset($prop['editname']); // force full name to be displayed // let the UI generate HTML and CSS representation for this calendar - $html = $this->ui->folder_list_item($id, $prop, $jsenv); + $html = $this->ui->folder_list_item($id, $prop, $jsenv, true); $prop += (array)$jsenv[$id]; $prop['editname'] = $editname; $prop['html'] = $html; diff --git a/plugins/kolab_notes/kolab_notes_ui.php b/plugins/kolab_notes/kolab_notes_ui.php index 45ddcbee..527e89bf 100644 --- a/plugins/kolab_notes/kolab_notes_ui.php +++ b/plugins/kolab_notes/kolab_notes_ui.php @@ -161,7 +161,7 @@ class kolab_notes_ui $prop = $data[$id]; $is_collapsed = false; // TODO: determine this somehow? - $content = $this->folder_list_item($id, $prop, $jsenv, $attrib['activeonly']); + $content = $this->folder_list_item($id, $prop, $jsenv); if (!empty($folder->children)) { $content .= html::tag('ul', array('style' => ($is_collapsed ? "display:none;" : null)), @@ -183,7 +183,7 @@ class kolab_notes_ui /** * Helper method to build a tasklist item (HTML content and js data) */ - public function folder_list_item($id, $prop, &$jsenv, $activeonly = false) + public function folder_list_item($id, $prop, &$jsenv, $checkbox = false) { if (!$prop['virtual']) { unset($prop['user_id']); @@ -212,7 +212,10 @@ class kolab_notes_ui return html::div(join(' ', $classes), html::a($attr + array('class' => 'listname', 'title' => $title, 'id' => $label_id), $prop['listname'] ?: $prop['name']) . ($prop['virtual'] ? '' : - html::tag('input', array('type' => 'checkbox', 'name' => '_list[]', 'value' => $id, 'checked' => $prop['active'], 'aria-labelledby' => $label_id)) . + ($checkbox ? + html::tag('input', array('type' => 'checkbox', 'name' => '_list[]', 'value' => $id, 'checked' => $prop['active'], 'aria-labelledby' => $label_id)) : + '' + ) . html::span('handle', '') . (isset($prop['subscribed']) ? html::a(array('href' => '#', 'class' => 'subscribed', 'title' => $this->plugin->gettext('foldersubscribe'), 'role' => 'checkbox', 'aria-checked' => $prop['subscribed'] ? 'true' : 'false'), ' ') :