aboutsummaryrefslogtreecommitdiffstats
path: root/addressbook/gui/widgets/e-minicard.c
diff options
context:
space:
mode:
authorChristopher James Lahey <clahey@helixcode.com>2000-11-06 09:06:09 +0800
committerChris Lahey <clahey@src.gnome.org>2000-11-06 09:06:09 +0800
commitac26ccfbdc8390cce592621407a26457c05f90b1 (patch)
tree3b56e03a6e688e43ddbe5c0416daa96520b48e87 /addressbook/gui/widgets/e-minicard.c
parent9ca299b427db9febb37208a33d238463f7a9b3bd (diff)
downloadgsoc2013-evolution-ac26ccfbdc8390cce592621407a26457c05f90b1.tar
gsoc2013-evolution-ac26ccfbdc8390cce592621407a26457c05f90b1.tar.gz
gsoc2013-evolution-ac26ccfbdc8390cce592621407a26457c05f90b1.tar.bz2
gsoc2013-evolution-ac26ccfbdc8390cce592621407a26457c05f90b1.tar.lz
gsoc2013-evolution-ac26ccfbdc8390cce592621407a26457c05f90b1.tar.xz
gsoc2013-evolution-ac26ccfbdc8390cce592621407a26457c05f90b1.tar.zst
gsoc2013-evolution-ac26ccfbdc8390cce592621407a26457c05f90b1.zip
Add menus items to the envelope printing stuff.
2000-11-05 Christopher James Lahey <clahey@helixcode.com> * 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
Diffstat (limited to 'addressbook/gui/widgets/e-minicard.c')
-rw-r--r--addressbook/gui/widgets/e-minicard.c13
1 files changed, 12 insertions, 1 deletions
diff --git a/addressbook/gui/widgets/e-minicard.c b/addressbook/gui/widgets/e-minicard.c
index c57e7adde7..4dda2cee1d 100644
--- a/addressbook/gui/widgets/e-minicard.c
+++ b/addressbook/gui/widgets/e-minicard.c
@@ -31,6 +31,7 @@
#include <gal/widgets/e-canvas.h>
#include <gal/widgets/e-popup-menu.h>
#include "addressbook/printing/e-contact-print.h"
+#include "addressbook/printing/e-contact-print-envelope.h"
#include "e-contact-editor.h"
#include "e-contact-save-as.h"
#include "e-minicard-view.h"
@@ -361,10 +362,18 @@ static void
print (GtkWidget *widget, EMinicard *minicard)
{
e_card_simple_sync_card(minicard->simple);
-
+
gtk_widget_show(e_contact_print_card_dialog_new(minicard->card));
}
+static void
+print_envelope (GtkWidget *widget, EMinicard *minicard)
+{
+ e_card_simple_sync_card(minicard->simple);
+
+ gtk_widget_show(e_contact_print_envelope_dialog_new(minicard->card));
+}
+
/* Callback for the add_card signal from the contact editor */
static void
add_card_cb (EContactEditor *ce, ECard *card, gpointer data)
@@ -477,11 +486,13 @@ e_minicard_event (GnomeCanvasItem *item, GdkEvent *event)
if (E_IS_MINICARD_VIEW(item->parent)) {
EPopupMenu menu[] = { {"Save as VCard", NULL, GTK_SIGNAL_FUNC(save_as), 0},
{"Print", NULL, GTK_SIGNAL_FUNC(print), 0},
+ {"Print Envelope", NULL, GTK_SIGNAL_FUNC(print_envelope), 0},
{"Delete", NULL, GTK_SIGNAL_FUNC(delete), 0},
{NULL, NULL, NULL, 0}};
e_popup_menu_run (menu, (GdkEventButton *)event, 0, 0, e_minicard);
} else {
EPopupMenu menu[] = { {"Save as VCard", NULL, GTK_SIGNAL_FUNC(save_as), 0},
+ {"Print Envelope", NULL, GTK_SIGNAL_FUNC(print_envelope), 0},
{"Print", NULL, GTK_SIGNAL_FUNC(print), 0},
{NULL, NULL, NULL, 0}};
e_popup_menu_run (menu, (GdkEventButton *)event, 0, 0, e_minicard);