diff options
Diffstat (limited to 'calendar/gui')
-rw-r--r-- | calendar/gui/gnome-cal.c | 21 |
1 files changed, 20 insertions, 1 deletions
diff --git a/calendar/gui/gnome-cal.c b/calendar/gui/gnome-cal.c index f0f240c172..b58a75bc08 100644 --- a/calendar/gui/gnome-cal.c +++ b/calendar/gui/gnome-cal.c @@ -1719,6 +1719,7 @@ gnome_calendar_destroy (GtkObject *object) GnomeCalendar *gcal; GnomeCalendarPrivate *priv; gchar *filename; + ECalModel *cal_model; g_return_if_fail (object != NULL); g_return_if_fail (GNOME_IS_CALENDAR (object)); @@ -1774,7 +1775,7 @@ gnome_calendar_destroy (GtkObject *object) calendar_config_remove_notification (GPOINTER_TO_UINT (l->data)); g_list_free (priv->notifications); priv->notifications = NULL; - + /* Save the TaskPad layout. */ filename = g_build_filename (calendar_component_peek_config_directory (calendar_component_peek ()), "TaskPad", NULL); @@ -1847,6 +1848,24 @@ gnome_calendar_destroy (GtkObject *object) g_object_unref (priv->memopad_menu); priv->memopad_menu = NULL; } + /* Disconnect all handlers */ + cal_model = e_calendar_view_get_model ((ECalendarView *)priv->week_view); + g_signal_handlers_disconnect_by_func (cal_model, + G_CALLBACK (view_progress_cb), gcal); + g_signal_handlers_disconnect_by_func (cal_model, + G_CALLBACK (view_done_cb), gcal); + + cal_model = e_calendar_table_get_model ((ECalendarTable *) priv->todo); + g_signal_handlers_disconnect_by_func (cal_model, + G_CALLBACK (view_progress_cb), gcal); + g_signal_handlers_disconnect_by_func (cal_model, + G_CALLBACK (view_done_cb), gcal); + + cal_model = e_memo_table_get_model ((EMemoTable *)priv->memo); + g_signal_handlers_disconnect_by_func (cal_model, + G_CALLBACK (view_progress_cb), gcal); + g_signal_handlers_disconnect_by_func (cal_model, + G_CALLBACK (view_done_cb), gcal); g_free (priv); gcal->priv = NULL; |