diff options
author | Christopher James Lahey <clahey@ximian.com> | 2001-09-22 06:08:13 +0800 |
---|---|---|
committer | Chris Lahey <clahey@src.gnome.org> | 2001-09-22 06:08:13 +0800 |
commit | 84adebbb963fc2e458018475a8e377873e254062 (patch) | |
tree | 3b8805dad352cfbdc4449096a2831b995bf86f63 /addressbook/gui/component | |
parent | b9e1d0f5a61a88e7cc9feaaa6bf931805ba96d63 (diff) | |
download | gsoc2013-evolution-84adebbb963fc2e458018475a8e377873e254062.tar gsoc2013-evolution-84adebbb963fc2e458018475a8e377873e254062.tar.gz gsoc2013-evolution-84adebbb963fc2e458018475a8e377873e254062.tar.bz2 gsoc2013-evolution-84adebbb963fc2e458018475a8e377873e254062.tar.lz gsoc2013-evolution-84adebbb963fc2e458018475a8e377873e254062.tar.xz gsoc2013-evolution-84adebbb963fc2e458018475a8e377873e254062.tar.zst gsoc2013-evolution-84adebbb963fc2e458018475a8e377873e254062.zip |
Hooked up print preview button.
2001-09-21 Christopher James Lahey <clahey@ximian.com>
* gui/component/addressbook.c (print_preview_cb): Hooked up print
preview button.
* gui/widgets/e-addressbook-view.c,
gui/widgets/e-addressbook-view.h
(e_addressbook_view_print_preview): Added this function.
* printing/e-contact-print.c, printing/e-contact-print.h
(e_contact_print_preview): Added this function.
svn path=/trunk/; revision=13071
Diffstat (limited to 'addressbook/gui/component')
-rw-r--r-- | addressbook/gui/component/addressbook.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/addressbook/gui/component/addressbook.c b/addressbook/gui/component/addressbook.c index cd5ba138a8..028a866909 100644 --- a/addressbook/gui/component/addressbook.c +++ b/addressbook/gui/component/addressbook.c @@ -130,6 +130,13 @@ print_cb (BonoboUIComponent *uih, void *user_data, const char *path) } static void +print_preview_cb (BonoboUIComponent *uih, void *user_data, const char *path) +{ + AddressbookView *view = (AddressbookView *) user_data; + e_addressbook_view_print_preview(view->view); +} + +static void stop_loading_cb (BonoboUIComponent *uih, void *user_data, const char *path) { AddressbookView *view = (AddressbookView *) user_data; @@ -204,6 +211,12 @@ update_command_state (EAddressbookView *eav, AddressbookView *view) "sensitive", e_addressbook_view_can_print (view->view) ? "1" : "0", NULL); + /* Print Contact */ + bonobo_ui_component_set_prop (uic, + "/commands/ContactsPrintPreview", + "sensitive", + e_addressbook_view_can_print (view->view) ? "1" : "0", NULL); + /* Delete Contact */ bonobo_ui_component_set_prop (uic, "/commands/ContactDelete", @@ -253,6 +266,7 @@ change_view_type (AddressbookView *view, EAddressbookViewType view_type) static BonoboUIVerb verbs [] = { BONOBO_UI_UNSAFE_VERB ("ContactsPrint", print_cb), + BONOBO_UI_UNSAFE_VERB ("ContactsPrintPreview", print_preview_cb), BONOBO_UI_UNSAFE_VERB ("ContactsSaveAsVCard", save_contact_cb), BONOBO_UI_UNSAFE_VERB ("ToolSearch", search_cb), |