From ee21a426dac2a32b788f80edc7a489bca1378ad4 Mon Sep 17 00:00:00 2001 From: Ettore Perazzoli Date: Mon, 20 Aug 2001 19:51:59 +0000 Subject: Don't set the paneds' positions if the respective left-hand elements [i.e. * e-shell-view.c (e_shell_view_load_settings): Don't set the paneds' positions if the respective left-hand elements [i.e. the shortcut bar and the folder bar] are hidden. (e_shell_view_show_folder_bar): Set the paned position to zero when hiding. (e_shell_view_show_shortcut_bar): Likewise. svn path=/trunk/; revision=12321 --- shell/ChangeLog | 9 +++++++++ shell/e-shell-view.c | 11 +++++++++-- 2 files changed, 18 insertions(+), 2 deletions(-) (limited to 'shell') diff --git a/shell/ChangeLog b/shell/ChangeLog index 72552e5af1..bb0b3b21f4 100644 --- a/shell/ChangeLog +++ b/shell/ChangeLog @@ -1,3 +1,12 @@ +2001-08-20 Ettore Perazzoli + + * e-shell-view.c (e_shell_view_load_settings): Don't set the + paneds' positions if the respective left-hand elements [i.e. the + shortcut bar and the folder bar] are hidden. + (e_shell_view_show_folder_bar): Set the paned position to zero + when hiding. + (e_shell_view_show_shortcut_bar): Likewise. + 2001-08-20 Ettore Perazzoli * e-shell-startup-wizard.c (finish_func): Don't free the returned diff --git a/shell/e-shell-view.c b/shell/e-shell-view.c index 722b4788c0..9dd90b2125 100644 --- a/shell/e-shell-view.c +++ b/shell/e-shell-view.c @@ -2006,6 +2006,7 @@ e_shell_view_show_shortcut_bar (EShellView *shell_view, e_paned_set_position (E_PANED (priv->hpaned), priv->hpaned_position); } } else { + e_paned_set_position (E_PANED (priv->hpaned), 0); if (GTK_WIDGET_VISIBLE (priv->shortcut_frame)) { gtk_widget_hide (priv->shortcut_frame); /* FIXME this is a private field! */ @@ -2044,6 +2045,8 @@ e_shell_view_show_folder_bar (EShellView *shell_view, e_shell_folder_title_bar_set_clickable (E_SHELL_FOLDER_TITLE_BAR (priv->folder_title_bar), FALSE); } else { + e_paned_set_position (E_PANED (priv->view_hpaned), 0); + if (GTK_WIDGET_VISIBLE (priv->storage_set_view_box)) { gtk_widget_hide (priv->storage_set_view_box); /* FIXME this is a private field! */ @@ -2353,12 +2356,16 @@ e_shell_view_load_settings (EShellView *shell_view, key = g_strconcat (prefix, "HPanedPosition", NULL); val = bonobo_config_get_long (db, key, NULL); - e_paned_set_position (E_PANED (priv->hpaned), val); + if (priv->shortcut_bar_shown) + e_paned_set_position (E_PANED (priv->hpaned), val); + priv->hpaned_position = val; g_free (key); key = g_strconcat (prefix, "ViewHPanedPosition", NULL); val = bonobo_config_get_long (db, key, NULL); - e_paned_set_position (E_PANED (priv->view_hpaned), val); + if (priv->folder_bar_shown) + e_paned_set_position (E_PANED (priv->view_hpaned), val); + priv->view_hpaned_position = val; g_free (key); key = g_strconcat (prefix, "DisplayedURI", NULL); -- cgit