From 77ba5399031de0aba831e267a4b6ed6f0d51ca6c Mon Sep 17 00:00:00 2001 From: Ettore Perazzoli Date: Thu, 25 Jan 2001 06:33:41 +0000 Subject: Get the addressbook to use the new "Show all" icon. svn path=/trunk/; revision=7802 --- addressbook/gui/component/addressbook.c | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) (limited to 'addressbook/gui/component') diff --git a/addressbook/gui/component/addressbook.c b/addressbook/gui/component/addressbook.c index fe0ad46e52..54b211bb16 100644 --- a/addressbook/gui/component/addressbook.c +++ b/addressbook/gui/component/addressbook.c @@ -281,6 +281,32 @@ BonoboUIVerb verbs [] = { BONOBO_UI_VERB_END }; +static void +set_pixmap (BonoboUIComponent *uic, + const char *xml_path, + const char *icon) +{ + char *path; + GdkPixbuf *pixbuf; + + path = g_concat_dir_and_file (EVOLUTION_DATADIR "/images/evolution", icon); + + pixbuf = gdk_pixbuf_new_from_file (path); + g_return_if_fail (pixbuf != NULL); + + bonobo_ui_util_set_pixbuf (uic, xml_path, pixbuf); + + gdk_pixbuf_unref (pixbuf); + + g_free (path); +} + +static void +update_pixmaps (BonoboUIComponent *uic) +{ + set_pixmap (uic, "/Toolbar/View All", "24_all_contacts.xpm"); +} + static void control_activate (BonoboControl *control, BonoboUIComponent *uic, @@ -305,6 +331,8 @@ control_activate (BonoboControl *control, update_view_type (view); + update_pixmaps (uic); + bonobo_ui_component_thaw (uic, NULL); } -- cgit v1.2.3