diff options
author | Charles Kerr <charles.kerr@canonical.com> | 2012-11-03 16:12:05 +0000 |
---|---|---|
committer | Tarmac <Unknown> | 2012-11-03 16:12:05 +0000 |
commit | 5427edfb6354e5d8be229ce42d877659734c5151 (patch) | |
tree | 9c8208bae29d91d058ef8e21479ee6aadd460e3b | |
parent | ef2b5d3c80fc35a11e165c5751c63d8763993e3a (diff) | |
parent | a4700c3cd510f6a0c8feba8fe34c35e306b222c0 (diff) | |
download | ayatana-indicator-datetime-5427edfb6354e5d8be229ce42d877659734c5151.tar.gz ayatana-indicator-datetime-5427edfb6354e5d8be229ce42d877659734c5151.tar.bz2 ayatana-indicator-datetime-5427edfb6354e5d8be229ce42d877659734c5151.zip |
Fix the bug by ensuring that the dbusmenuitems in our appointment menuitem array are hidden if they're not currently in use. Fixes: https://bugs.launchpad.net/bugs/1069177.
Approved by Lars Uebernickel, PS Jenkins bot.
-rw-r--r-- | src/datetime-service.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/datetime-service.c b/src/datetime-service.c index b34c23e..e08e50d 100644 --- a/src/datetime-service.c +++ b/src/datetime-service.c @@ -399,8 +399,10 @@ hide_all_appointments (void) { int i; - for (i=0; i<MAX_APPOINTMENT_MENUITEMS; i++) + for (i=0; i<MAX_APPOINTMENT_MENUITEMS; i++) { dbusmenu_menuitem_property_set_bool(appointments[i], DBUSMENU_MENUITEM_PROP_ENABLED, FALSE); + dbusmenu_menuitem_property_set_bool(appointments[i], DBUSMENU_MENUITEM_PROP_VISIBLE, FALSE); + } } static gboolean @@ -415,8 +417,6 @@ month_changed_cb (DbusmenuMenuitem * menuitem, gchar *name, GVariant *variant, g user. */ dbusmenu_menuitem_property_remove(menuitem, CALENDAR_MENUITEM_PROP_MARKS); - hide_all_appointments (); - g_idle_add(update_appointment_menu_items_idle, NULL); return TRUE; } @@ -446,8 +446,6 @@ day_selected_cb (DbusmenuMenuitem * menuitem, gchar *name, GVariant *variant, gu } } - hide_all_appointments (); - start_time_appointments = new_time; g_debug("Received day-selected with timestamp: %d -> %s",(int)start_time_appointments, ctime(&start_time_appointments)); |