diff options
Diffstat (limited to 'plugins/itip-formatter/itip-formatter.c')
-rw-r--r-- | plugins/itip-formatter/itip-formatter.c | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/plugins/itip-formatter/itip-formatter.c b/plugins/itip-formatter/itip-formatter.c index d51f54cb1b..6d5f532206 100644 --- a/plugins/itip-formatter/itip-formatter.c +++ b/plugins/itip-formatter/itip-formatter.c @@ -273,6 +273,12 @@ cal_opened_cb (ECal *ecal, ECalendarStatus status, gpointer data) ITIP_VIEW_INFO_ITEM_TYPE_WARNING, _("Failed to load the calendar '%s'"), e_source_peek_name (source)); + + if (pitip->current_ecal == ecal) { + pitip->current_ecal = NULL; + itip_view_set_buttons_sensitive (ITIP_VIEW (pitip->view), FALSE); + } + g_hash_table_remove (pitip->ecals[source_type], e_source_peek_uid (source)); return; } @@ -391,6 +397,11 @@ find_cal_opened_cb (ECal *ecal, ECalendarStatus status, gpointer data) ITIP_VIEW_INFO_ITEM_TYPE_WARNING, _("Failed to load the calendar '%s'"), e_source_peek_name (source)); + if (pitip->current_ecal == ecal) { + pitip->current_ecal = NULL; + itip_view_set_buttons_sensitive (ITIP_VIEW (pitip->view), FALSE); + } + g_hash_table_remove (pitip->ecals[source_type], e_source_peek_uid (source)); goto cleanup; } @@ -444,7 +455,6 @@ find_cal_opened_cb (ECal *ecal, ECalendarStatus status, gpointer data) itip_view_set_show_recur_check (ITIP_VIEW (pitip->view), FALSE); } - cleanup: d(printf ("Decreasing itip formatter search count to %d\n", fd->count)); |