aboutsummaryrefslogtreecommitdiffstats
path: root/mail/folder-browser-ui.c
diff options
context:
space:
mode:
authorJeffrey Stedfast <fejj@ximian.com>2002-03-05 06:01:12 +0800
committerJeffrey Stedfast <fejj@src.gnome.org>2002-03-05 06:01:12 +0800
commitc5f85f4f331f5b8117d24dbec871a312d712e654 (patch)
treefece9c1f720d4e2ec314c2d7ea3dea9b195ce176 /mail/folder-browser-ui.c
parent944f73858b5d8091199b6d3a9b243e797fad3e48 (diff)
downloadgsoc2013-evolution-c5f85f4f331f5b8117d24dbec871a312d712e654.tar.gz
gsoc2013-evolution-c5f85f4f331f5b8117d24dbec871a312d712e654.tar.zst
gsoc2013-evolution-c5f85f4f331f5b8117d24dbec871a312d712e654.zip
Connect to the focus-in/out events on the message-list so that we can
2002-03-04 Jeffrey Stedfast <fejj@ximian.com> * folder-browser.c (my_folder_browser_init): Connect to the focus-in/out events on the message-list so that we can disable the EditInvertSelection and EditSelectThread menu items when the message-list is not in focus. * folder-browser-ui.c (folder_browser_ui_message_list_unfocus): New function to de-sensitize some items if the message-list is not in focus. (folder_browser_ui_message_list_focus): New function to sensitize some items if the message-list is not in focus. * mail-callbacks.c (invert_selection): Only invert the selection of the message-list if it is the widget in focus. * message-list.c (message_list_select): Do not explicitly grab the focus here. svn path=/trunk/; revision=15909
Diffstat (limited to 'mail/folder-browser-ui.c')
-rw-r--r--mail/folder-browser-ui.c24
1 files changed, 23 insertions, 1 deletions
diff --git a/mail/folder-browser-ui.c b/mail/folder-browser-ui.c
index cd79be08ea..207d6344bd 100644
--- a/mail/folder-browser-ui.c
+++ b/mail/folder-browser-ui.c
@@ -144,7 +144,7 @@ static EPixmap message_pixcache [] = {
E_PIXMAP ("/Toolbar/MailMessageToolbar/MessageMove", "buttons/move-message.png"),
E_PIXMAP ("/Toolbar/MailMessageToolbar/MessageCopy", "buttons/copy-message.png"),
E_PIXMAP ("/Toolbar/MailMessageToolbar/MessageDelete", "buttons/delete-message.png"),
-
+
E_PIXMAP ("/Toolbar/MailNextButtons/MailNext", "buttons/next-message.png"),
E_PIXMAP ("/Toolbar/MailNextButtons/MailPrevious", "buttons/previous-message.png"),
@@ -308,6 +308,28 @@ folder_browser_ui_discard_view_menus (FolderBrowser *fb)
fb->view_menus = NULL;
}
+void
+folder_browser_ui_message_list_focus (FolderBrowser *fb)
+{
+ g_assert (fb->uicomp != NULL);
+
+ bonobo_ui_component_set_prop (fb->uicomp, "/commands/EditInvertSelection",
+ "sensitive", "1", NULL);
+ bonobo_ui_component_set_prop (fb->uicomp, "/commands/EditSelectThread",
+ "sensitive", "1", NULL);
+}
+
+void
+folder_browser_ui_message_list_unfocus (FolderBrowser *fb)
+{
+ g_assert (fb->uicomp != NULL);
+
+ bonobo_ui_component_set_prop (fb->uicomp, "/commands/EditInvertSelection",
+ "sensitive", "0", NULL);
+ bonobo_ui_component_set_prop (fb->uicomp, "/commands/EditSelectThread",
+ "sensitive", "0", NULL);
+}
+
static void
folder_browser_setup_property_menu (FolderBrowser *fb,
BonoboUIComponent *uic)