aboutsummaryrefslogtreecommitdiffstats
path: root/mail/em-folder-browser.c
diff options
context:
space:
mode:
authorRodney Dawes <dobey@novell.com>2005-06-01 02:20:52 +0800
committerRodney Dawes <dobey@src.gnome.org>2005-06-01 02:20:52 +0800
commitff6a38b627b7052ef42322ee8fbaf730cb6aec89 (patch)
tree72110cfb8d72b99edb17137744dc5142b454ee52 /mail/em-folder-browser.c
parent6983c4ecf4d016972a48b96dc697ff57167ec718 (diff)
downloadgsoc2013-evolution-ff6a38b627b7052ef42322ee8fbaf730cb6aec89.tar.gz
gsoc2013-evolution-ff6a38b627b7052ef42322ee8fbaf730cb6aec89.tar.zst
gsoc2013-evolution-ff6a38b627b7052ef42322ee8fbaf730cb6aec89.zip
Update these methods to use the listener method of access from bonobo as
2005-05-31 Rodney Dawes <dobey@novell.com> * em-folder-browser.c (emfb_view_hide_read, emfb_view_show_selected): (emfb_view_show_all): Update these methods to use the listener method of access from bonobo as they are radio buttons now (emfb_verbs): Comment out the verbs for the above methods, as they are configured through add_listener now (emfb_enable_map): s/ViewHideSelected/ViewShowSelected/ (emfb_activate): Add the listeners for the radio buttons for filtering the message list for unread, selected, or all messages svn path=/trunk/; revision=29432
Diffstat (limited to 'mail/em-folder-browser.c')
-rw-r--r--mail/em-folder-browser.c17
1 files changed, 12 insertions, 5 deletions
diff --git a/mail/em-folder-browser.c b/mail/em-folder-browser.c
index c93c027bf7..820fa27321 100644
--- a/mail/em-folder-browser.c
+++ b/mail/em-folder-browser.c
@@ -691,7 +691,7 @@ emfb_mark_all_read(BonoboUIComponent *uid, void *data, const char *path)
}
static void
-emfb_view_hide_read(BonoboUIComponent *uid, void *data, const char *path)
+emfb_view_hide_read(BonoboUIComponent *uic, const char *path, Bonobo_UIComponent_EventType type, const char *state, void *data)
{
EMFolderView *emfv = data;
@@ -699,7 +699,7 @@ emfb_view_hide_read(BonoboUIComponent *uid, void *data, const char *path)
}
static void
-emfb_view_hide_selected(BonoboUIComponent *uid, void *data, const char *path)
+emfb_view_show_selected(BonoboUIComponent *uic, const char *path, Bonobo_UIComponent_EventType type, const char *state, void *data)
{
EMFolderView *emfv = data;
GPtrArray *uids;
@@ -712,7 +712,7 @@ emfb_view_hide_selected(BonoboUIComponent *uid, void *data, const char *path)
}
static void
-emfb_view_show_all(BonoboUIComponent *uid, void *data, const char *path)
+emfb_view_show_all(BonoboUIComponent *uic, const char *path, Bonobo_UIComponent_EventType type, const char *state, void *data)
{
EMFolderView *emfv = data;
@@ -782,9 +782,12 @@ static BonoboUIVerb emfb_verbs[] = {
BONOBO_UI_UNSAFE_VERB ("FolderExpunge", emfb_folder_expunge),
/* HideDeleted is a toggle */
BONOBO_UI_UNSAFE_VERB ("MessageMarkAllAsRead", emfb_mark_all_read),
+ /*
+ These are radio buttons now
BONOBO_UI_UNSAFE_VERB ("ViewHideRead", emfb_view_hide_read),
- BONOBO_UI_UNSAFE_VERB ("ViewHideSelected", emfb_view_hide_selected),
+ BONOBO_UI_UNSAFE_VERB ("ViewShowSelected", emfb_view_show_selected),
BONOBO_UI_UNSAFE_VERB ("ViewShowAll", emfb_view_show_all),
+ */
/* ViewThreaded is a toggle */
BONOBO_UI_UNSAFE_VERB ("FolderCopy", emfb_folder_copy),
@@ -822,7 +825,7 @@ static const EMFolderViewEnable emfb_enable_map[] = {
{ "FolderRename", EM_POPUP_SELECT_FOLDER },
{ "MailPost", EM_POPUP_SELECT_FOLDER },
{ "MessageMarkAllAsRead", EM_POPUP_SELECT_FOLDER },
- { "ViewHideSelected", EM_POPUP_SELECT_MANY },
+ { "ViewShowSelected", EM_POPUP_SELECT_MANY },
{ NULL },
};
@@ -1145,6 +1148,10 @@ emfb_activate(EMFolderView *emfv, BonoboUIComponent *uic, int act)
/* FIXME: Selection state */
+ bonobo_ui_component_add_listener(uic, "ViewHideRead", emfb_view_hide_read, emfv);
+ bonobo_ui_component_add_listener(uic, "ViewShowSelected", emfb_view_show_selected, emfv);
+ bonobo_ui_component_add_listener(uic, "ViewShowAll", emfb_view_show_all, emfv);
+
/* FIXME: property menu customisation */
/*folder_browser_setup_property_menu (fb, fb->uicomp);*/