From be88a44705a7decc5cf3fb87704f1d6608fea857 Mon Sep 17 00:00:00 2001 From: Federico Mena Quintero Date: Thu, 31 May 2001 23:05:41 +0000 Subject: Added fields for the GalViewMenus and GalViewCollection; we need to keep 2001-05-31 Federico Mena Quintero * gui/widgets/e-addressbook-view.h (EAddressbookView): Added fields for the GalViewMenus and GalViewCollection; we need to keep them around while the component is active. * gui/widgets/e-addressbook-view.c (e_addressbook_view_setup_menus): Plug leak; unref the spec. Unref the factories. Do not unref the collection, since we need it for the signal emission (okay, so the views object adds a reference to it, but if we are interested in it we should keep a reference anyways). (e_addressbook_view_setup_menus): Create the collection and views on the EAddressbookView's fields so that we can keep them around. (e_addressbook_view_discard_menus): New function; gets rid of the collection and views objects. * gui/component/addressbook.c (control_activate_cb): Call e_addressbook_view_discard_menus(). svn path=/trunk/; revision=10074 --- addressbook/gui/widgets/e-addressbook-view.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'addressbook/gui/widgets/e-addressbook-view.h') diff --git a/addressbook/gui/widgets/e-addressbook-view.h b/addressbook/gui/widgets/e-addressbook-view.h index 049376c96f..d97cd58f55 100644 --- a/addressbook/gui/widgets/e-addressbook-view.h +++ b/addressbook/gui/widgets/e-addressbook-view.h @@ -23,7 +23,9 @@ #include #include +#include #include "e-addressbook-model.h" +#include "widgets/menus/gal-view-menus.h" #include "addressbook/backend/ebook/e-book.h" #ifdef __cplusplus @@ -75,6 +77,10 @@ struct _EAddressbookView GtkWidget *widget; GtkWidget *vbox; + + /* Menus handler and the view collection */ + GalViewCollection *view_collection; + GalViewMenus *view_menus; }; struct _EAddressbookViewClass @@ -93,6 +99,7 @@ GtkType e_addressbook_view_get_type (void); void e_addressbook_view_setup_menus (EAddressbookView *view, BonoboUIComponent *uic); +void e_addressbook_view_discard_menus (EAddressbookView *view); void e_addressbook_view_print (EAddressbookView *view); void e_addressbook_view_delete_selection (EAddressbookView *view); -- cgit v1.2.3