aboutsummaryrefslogtreecommitdiffstats
path: root/mail/folder-browser-factory.c
diff options
context:
space:
mode:
author4 <NotZed@Ximian.com>2001-10-24 10:56:06 +0800
committerMichael Zucci <zucchi@src.gnome.org>2001-10-24 10:56:06 +0800
commite4fa983be5e2c6a6496ba02f5391800ecee4575d (patch)
tree648176650d5c3f1e2b8dac2f225bc2ca89fe6069 /mail/folder-browser-factory.c
parentd6088ab1f0e058c35cab4ef247231ca07d456de4 (diff)
downloadgsoc2013-evolution-e4fa983be5e2c6a6496ba02f5391800ecee4575d.tar.gz
gsoc2013-evolution-e4fa983be5e2c6a6496ba02f5391800ecee4575d.tar.zst
gsoc2013-evolution-e4fa983be5e2c6a6496ba02f5391800ecee4575d.zip
all this crap just to make the print icon desensitive at the right time.
fix for #10346 2001-10-24 <NotZed@Ximian.com> * message-browser.c (message_browser_message_loaded): Call ui_message_loaded when we are. * folder-browser-factory.c (control_activate): Freeze/thaw around all updates. (control_deactivate): Freeze/thaw around all updates. * folder-browser.c (folder_browser_init): Setup a hashtable to keep track of *our* sensitise state, so we can optimise pushes to bonobo. (folder_browser_finalise): Free hash here. (folder_browser_set_message_preview): Call a ui_message_loaded, even though it isn't, so it updates sensitivities right. (done_message_selected): Call ui_message_loaded when it really is, rather than the very fucked up idea of reversing the loaded_uid check. * folder-browser-ui.c (folder_browser_ui_set_selection_state): Dont enable the message-enabled options if the message display is hidden, e.g. print, view headers, etc. (folder_browser_ui_rm_all): Forget sensitise state. (fbui_sensitise_item): Sensitise items via a current-state table, so we dont have to do bonobo calls every time. (folder_browser_setup_property_menu): Call sensitise_item. (folder_browser_ui_add_message): (folder_browser_ui_add_global): Leave current set_prop "sensitive" for the stop button, so it doesn't get lost by the stuff in mail-mt.c (fbui_real_sensitize_items): Removed. (fbui_sensitize_timeout): Cleaned up, use sensitise_item to do work. (folder_browser_ui_message_loaded): Setup sensitive based on preview_shown too. (folder_browser_ui_set_selection_state): And here too. svn path=/trunk/; revision=13972
Diffstat (limited to 'mail/folder-browser-factory.c')
-rw-r--r--mail/folder-browser-factory.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/mail/folder-browser-factory.c b/mail/folder-browser-factory.c
index 86a51a0d59..c398e8b748 100644
--- a/mail/folder-browser-factory.c
+++ b/mail/folder-browser-factory.c
@@ -87,10 +87,14 @@ control_activate (BonoboControl *control,
folder_browser = bonobo_control_get_widget (control);
folder_browser_set_ui_component (FOLDER_BROWSER (folder_browser), uic);
+ bonobo_ui_component_freeze (uic, NULL);
+
folder_browser_ui_add_global (fb);
folder_browser_ui_add_list (fb);
folder_browser_ui_add_message (fb);
+ bonobo_ui_component_thaw (uic, NULL);
+
folder_browser_set_shell_view(fb, fb_get_svi (control));
if (fb->folder)
@@ -102,8 +106,12 @@ control_deactivate (BonoboControl *control,
BonoboUIComponent *uic,
FolderBrowser *fb)
{
+ bonobo_ui_component_freeze (uic, NULL);
+
folder_browser_ui_rm_list (fb);
folder_browser_ui_rm_all (fb);
+
+ bonobo_ui_component_thaw (uic, NULL);
if (fb->folder)
mail_sync_folder (fb->folder, NULL, NULL);