From 46cea1ca0b850344f45ff1647a179a88f2299555 Mon Sep 17 00:00:00 2001 From: Peter Williams Date: Wed, 28 Aug 2002 18:14:38 +0000 Subject: Add some new flags for sensitizing nodes based on the flags of the 2002-08-28 Peter Williams * folder-browser-ui.c (default_ui_nodes): Add some new flags for sensitizing nodes based on the flags of the currently selected messages. (folder_browser_ui_add_message): Reset the sensitivity cache when we re-add UI items. (folder_browser_ui_add_list): Same. (folder_browser_ui_add_global): Same. (fbui_sensitise_item): Only cache the sensitivity in the hash table if we actually change it. (folder_browser_ui_scan_selection): New function, getting the bulk of the contents of folder_browser_ui_set_selection_state. Now with code to iterate over the currently selected messages and check their flags so we can sensitize based on them. (folder_browser_ui_set_selection_state): Now just set the selection state if necessary and pass off to _scan_selection. Don't skip of we're trying to go from SELSTATE_SINGLE to SELSTATE_SINGLE, eg, as the flags of the selected messages may have changed. * folder-browser-ui.h: Prototype folder_browser_ui_scan_selection. * folder-browser.c (main_folder_changed): Call folder_browser_ui_scan_selection as the flags on a selected message may have just changed. svn path=/trunk/; revision=17893 --- mail/folder-browser.c | 1 + 1 file changed, 1 insertion(+) (limited to 'mail/folder-browser.c') diff --git a/mail/folder-browser.c b/mail/folder-browser.c index 1ef7039d7c..6c9b13d68c 100644 --- a/mail/folder-browser.c +++ b/mail/folder-browser.c @@ -823,6 +823,7 @@ static void main_folder_changed(CamelObject *o, void *event_data, void *data) /* so some corba unref doesnt blow us away while we're busy */ gtk_object_ref((GtkObject *)fb); update_status_bar(fb); + folder_browser_ui_scan_selection (fb); gtk_object_unref((GtkObject *)fb); } -- cgit