From 7de0e8cb10046bd29e400f1120eec6d593781156 Mon Sep 17 00:00:00 2001 From: JP Rosevear Date: Wed, 31 Jul 2002 20:03:55 +0000 Subject: we no longer need to manually save the state (e_tasks_open): we no longer 2002-07-31 JP Rosevear * gui/e-tasks.c (e_tasks_destroy): we no longer need to manually save the state (e_tasks_open): we no longer need to manually load the state (display_view_cb): attach the gal view to the table Fixes #27894 svn path=/trunk/; revision=17656 --- calendar/ChangeLog | 9 +++++++++ calendar/gui/e-tasks.c | 39 +-------------------------------------- 2 files changed, 10 insertions(+), 38 deletions(-) (limited to 'calendar') diff --git a/calendar/ChangeLog b/calendar/ChangeLog index 5f59154803..56c7a06016 100644 --- a/calendar/ChangeLog +++ b/calendar/ChangeLog @@ -1,3 +1,12 @@ +2002-07-31 JP Rosevear + + * gui/e-tasks.c (e_tasks_destroy): we no longer need to manually + save the state + (e_tasks_open): we no longer need to manually load the state + (display_view_cb): attach the gal view to the table + + Fixes #27894 + 2002-07-29 JP Rosevear * gui/e-day-view.c (e_day_view_find_work_week_start): make sure diff --git a/calendar/gui/e-tasks.c b/calendar/gui/e-tasks.c index d042a02f08..61c55e1598 100644 --- a/calendar/gui/e-tasks.c +++ b/calendar/gui/e-tasks.c @@ -68,8 +68,6 @@ static void e_tasks_destroy (GtkObject *object); static void cal_opened_cb (CalClient *client, CalClientOpenStatus status, gpointer data); -static char* e_tasks_get_config_filename (ETasks *tasks); - /* Signal IDs */ enum { SELECTION_CHANGED, @@ -297,7 +295,6 @@ e_tasks_destroy (GtkObject *object) { ETasks *tasks; ETasksPrivate *priv; - char *config_filename; g_return_if_fail (object != NULL); g_return_if_fail (E_IS_TASKS (object)); @@ -305,12 +302,6 @@ e_tasks_destroy (GtkObject *object) tasks = E_TASKS (object); priv = tasks->priv; - /* Save the ETable layout. */ - config_filename = e_tasks_get_config_filename (tasks); - e_calendar_table_save_state (E_CALENDAR_TABLE (priv->tasks_view), - config_filename); - g_free (config_filename); - if (priv->client) { gtk_object_unref (GTK_OBJECT (priv->client)); priv->client = NULL; @@ -342,7 +333,6 @@ e_tasks_open (ETasks *tasks, char *file) { ETasksPrivate *priv; - char *config_filename; char *message; EUri *uri; char *real_uri; @@ -371,10 +361,6 @@ e_tasks_open (ETasks *tasks, return FALSE; } - config_filename = e_tasks_get_config_filename (tasks); - e_calendar_table_load_state (E_CALENDAR_TABLE (priv->tasks_view), - config_filename); - g_free (config_filename); g_free (real_uri); e_uri_free (uri); @@ -466,28 +452,6 @@ cal_opened_cb (CalClient *client, } } - -static char* -e_tasks_get_config_filename (ETasks *tasks) -{ - ETasksPrivate *priv; - char *url, *filename; - - priv = tasks->priv; - - url = g_strdup (cal_client_get_uri (priv->client)); - - /* This turns all funny characters into '_', in the string itself. */ - e_filename_make_safe (url); - - filename = g_strdup_printf ("%s/config/et-header-%s", evolution_dir, - url); - g_free (url); - - return filename; -} - - /** * e_tasks_get_cal_client: * @tasks: An #ETasks. @@ -698,8 +662,7 @@ display_view_cb (GalViewInstance *instance, GalView *view, gpointer data) tasks = E_TASKS (data); if (GAL_IS_VIEW_ETABLE (view)) { - e_table_set_state_object (e_table_scrolled_get_table (E_TABLE_SCROLLED (E_CALENDAR_TABLE (tasks->priv->tasks_view)->etable)), - GAL_VIEW_ETABLE (view)->state); + gal_view_etable_attach_table (GAL_VIEW_ETABLE (view), e_table_scrolled_get_table (E_TABLE_SCROLLED (E_CALENDAR_TABLE (tasks->priv->tasks_view)->etable))); } } -- cgit v1.2.3