aboutsummaryrefslogtreecommitdiffstats
path: root/addressbook/gui/widgets/e-addressbook-view.h
diff options
context:
space:
mode:
authorChris Toshok <toshok@ximian.com>2003-12-18 04:30:44 +0800
committerChris Toshok <toshok@src.gnome.org>2003-12-18 04:30:44 +0800
commitcce087033f4d2d3bf25995108d598230523e1b40 (patch)
treeb35d9306c4129e51090e962a3af229cdddfb9461 /addressbook/gui/widgets/e-addressbook-view.h
parente6d897628ea525ad11a4bedcc6fcd9c89ee429ee (diff)
downloadgsoc2013-evolution-cce087033f4d2d3bf25995108d598230523e1b40.tar
gsoc2013-evolution-cce087033f4d2d3bf25995108d598230523e1b40.tar.gz
gsoc2013-evolution-cce087033f4d2d3bf25995108d598230523e1b40.tar.bz2
gsoc2013-evolution-cce087033f4d2d3bf25995108d598230523e1b40.tar.lz
gsoc2013-evolution-cce087033f4d2d3bf25995108d598230523e1b40.tar.xz
gsoc2013-evolution-cce087033f4d2d3bf25995108d598230523e1b40.tar.zst
gsoc2013-evolution-cce087033f4d2d3bf25995108d598230523e1b40.zip
install the "source" property. (eab_view_init): init eav->source to NULL.
2003-12-17 Chris Toshok <toshok@ximian.com> * gui/widgets/e-addressbook-view.c (eab_view_class_init): install the "source" property. (eab_view_init): init eav->source to NULL. (eab_view_dispose): disconnect the ecml_changed_id and unref source. (eab_view_new): create the search bar here. (view_preview): c&p the mailer's code mostly for this - this is the toggle listener for the Preview Pane menuitem. (setup_menus): add a listener for the ContactsViewPreview toggle. (eab_view_set_property): sensitize the search bar based on whether or not we have a book set. This makes it so you can't search until the book is loaded. Also add handling for the "source" attribute and print a warning when it's set multiple times (something that's not supported at the moment.) (eab_view_get_property): add "source" case. (search_activated, query_changed, compare_subitems, make_subitems, ecml_changed, get_master_list, connect_master_list_changed): move this here from addressbook.c (eab_view_show_contact_preview): implement - just show or hide the scrolled window. (eab_view_setup_menus): call e_search_bar_set_ui_component here, kind of a hack. * gui/widgets/e-addressbook-view.h: make this inherit from GtkVBox instead of GtkEventBox since we'll be packing children. Add a prototype for eab_view_show_contact_preview. * gui/component/addressbook.c (get_current_view): return the EABView associated with the active notebook page. (save_contact_cb): use the current view. (view_contact_cb): same. (search_cb): same. (delete_contact_cb): same. (print_cb): same. (print_preview_cb): same. (stop_loading_cb): same. (cut_contacts_cb): same. (copy_contacts_cb): same. (paste_contacts_cb): same. (select_all_contacts_cb): same. (send_contact_cb): same. (send_contact_to_cb): same. (copy_contact_to_cb): same. (move_contact_to_cb): same. (update_command_state): same. (change_view_type): nuke, nothing uses this. (control_activate): use the current view. (control_activate_cb): same. (source_list_changed_cb): new function, remove the notebook pages (and destroy the EABView's) for sources that no longer exist. (addressbook_view_clear): dispose of the uid_to_view hash. (book_open_cb): store the ESource on the EABView too. this function now takes a struct containing both EABView and ESource since we can't store either in the AddressbookView. (set_prop): if we have a view already for this uid, bring it up. otherwise create a new one and start the book loading. (addressbook_search_activated): nuked - this is being moved to e-addressbook-view. (addressbook_query_changed): same. (compare_subitems, make_subitems, ecml_changed, connect_master_list_changed): same. (addressbook_new_control): simplify things a bunch. create a notebook to store the views in. the search/vbox stuff is gone. use e_source_list_new_for_gconf_default, and handle the source list's "changed" signal. svn path=/trunk/; revision=23971
Diffstat (limited to 'addressbook/gui/widgets/e-addressbook-view.h')
-rw-r--r--addressbook/gui/widgets/e-addressbook-view.h17
1 files changed, 13 insertions, 4 deletions
diff --git a/addressbook/gui/widgets/e-addressbook-view.h b/addressbook/gui/widgets/e-addressbook-view.h
index f819704550..c03c1e3d00 100644
--- a/addressbook/gui/widgets/e-addressbook-view.h
+++ b/addressbook/gui/widgets/e-addressbook-view.h
@@ -20,13 +20,15 @@
#ifndef __EAB_VIEW_H__
#define __EAB_VIEW_H__
-#include <gtk/gtkeventbox.h>
+#include <gtk/gtkvbox.h>
#include <bonobo/bonobo-ui-component.h>
#include <gal/menus/gal-view-instance.h>
#include <libebook/e-book.h>
#include "e-addressbook-model.h"
#include "eab-contact-display.h"
#include "widgets/menus/gal-view-menus.h"
+#include "widgets/misc/e-search-bar.h"
+#include "widgets/misc/e-filter-bar.h"
G_BEGIN_DECLS
@@ -59,7 +61,7 @@ typedef struct _EABViewClass EABViewClass;
struct _EABView
{
- GtkEventBox parent;
+ GtkVBox parent;
/* item specific fields */
EABViewType view_type;
@@ -70,6 +72,7 @@ struct _EABView
GList *clipboard_contacts;
EBook *book;
+ ESource *source;
char *query;
guint editable : 1;
@@ -85,11 +88,16 @@ struct _EABView
GalViewMenus *view_menus;
GalView *current_view;
BonoboUIComponent *uic;
+
+ /* the search bar and related machinery */
+ ESearchBar *search;
+ gint ecml_changed_id;
+
};
struct _EABViewClass
{
- GtkEventBoxClass parent_class;
+ GtkVBoxClass parent_class;
/*
* Signals
@@ -103,9 +111,10 @@ struct _EABViewClass
GtkWidget *eab_view_new (void);
GType eab_view_get_type (void);
+void eab_view_show_contact_preview (EABView *view, gboolean show);
+
void eab_view_setup_menus (EABView *view,
BonoboUIComponent *uic);
-
void eab_view_discard_menus (EABView *view);
void eab_view_save_as (EABView *view);