Only show calendars in f/b preference that are supposed to be displayed.
authorJan Schneider <jan@horde.org>
Thu, 6 Jan 2011 17:45:30 +0000 (18:45 +0100)
committerJan Schneider <jan@horde.org>
Thu, 6 Jan 2011 17:45:30 +0000 (18:45 +0100)
kronolith/lib/Application.php

index 6ae73d6..249e355 100644 (file)
@@ -187,7 +187,9 @@ class Kronolith_Application extends Horde_Registry_Application
             if (!$prefs->isLocked('fb_cals')) {
                 $fb_list = array();
                 foreach (Kronolith::listCalendars() as $fb_cal => $cal) {
-                    $fb_list[htmlspecialchars($fb_cal)] = htmlspecialchars($cal->name());
+                    if ($cal->display()) {
+                        $fb_list[htmlspecialchars($fb_cal)] = htmlspecialchars($cal->name());
+                    }
                 }
                 $ui->override['fb_cals'] = $fb_list;
             }