From ac26ccfbdc8390cce592621407a26457c05f90b1 Mon Sep 17 00:00:00 2001 From: Christopher James Lahey Date: Mon, 6 Nov 2000 01:06:09 +0000 Subject: Add menus items to the envelope printing stuff. 2000-11-05 Christopher James Lahey * contact-editor/e-contact-editor.c, gui/widgets/e-addressbook-view.c, gui/widgets/e-minicard.c: Add menus items to the envelope printing stuff. * gui/component/addressbook.c: Hook up the search menu. * gui/widgets/e-addressbook-search.c, gui/widgets/e-addressbook-search.h: Add the search menu. * printing/Makefile.am: Add e-contact-print-envelope.c and e-contact-print-envelope.h. * printing/e-contact-print-envelope.c, printing/e-contact-print-envelope.h: Added envelope printing. svn path=/trunk/; revision=6408 --- addressbook/gui/contact-editor/e-contact-editor.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'addressbook/gui/contact-editor/e-contact-editor.c') diff --git a/addressbook/gui/contact-editor/e-contact-editor.c b/addressbook/gui/contact-editor/e-contact-editor.c index aa2f4cffc2..c4e8ed8640 100644 --- a/addressbook/gui/contact-editor/e-contact-editor.c +++ b/addressbook/gui/contact-editor/e-contact-editor.c @@ -33,6 +33,7 @@ #include #include #include "addressbook/printing/e-contact-print.h" +#include "addressbook/printing/e-contact-print-envelope.h" /* Signal IDs */ enum { @@ -713,6 +714,20 @@ print_cb (BonoboUIComponent *uih, void *data, const char *path) gtk_widget_show(e_contact_print_card_dialog_new(ce->card)); } +/* Emits the signal to request printing a card */ +static void +print_envelope_cb (BonoboUIComponent *uih, void *data, const char *path) +{ + EContactEditor *ce; + + ce = E_CONTACT_EDITOR (data); + + extract_info (ce); + e_card_simple_sync_card (ce->simple); + + gtk_widget_show(e_contact_print_envelope_dialog_new(ce->card)); +} + /* Toolbar/Save and Close callback */ static void tb_save_and_close_cb (BonoboUIComponent *uih, void *data, const char *path) @@ -731,6 +746,7 @@ BonoboUIVerb verbs [] = { BONOBO_UI_UNSAFE_VERB ("ContactEditorSaveClose", tb_save_and_close_cb), BONOBO_UI_UNSAFE_VERB ("ContactEditorDelete", delete_cb), BONOBO_UI_UNSAFE_VERB ("ContactEditorPrint", print_cb), + BONOBO_UI_UNSAFE_VERB ("ContactEditorPrintEnvelope", print_envelope_cb), /* BONOBO_UI_UNSAFE_VERB ("ContactEditorPageSetup", file_page_setup_menu), */ BONOBO_UI_UNSAFE_VERB ("ContactEditorClose", file_close_cb), -- cgit v1.2.3