commit 74e350f0eae016de899ae2d6100d5af93dab83d6
parent d92e8ce486b08c5697014a24abbdaa8f662dc542
Author: Colin Leroy <colin@colino.net>
Date: Sun, 13 Nov 2011 14:09:03 +0000
2011-11-13 [colin] 3.7.10cvs85
* src/compose.c
Make compose windows printable
Diffstat:
4 files changed, 22 insertions(+), 1 deletion(-)
diff --git a/ChangeLog b/ChangeLog
@@ -1,3 +1,8 @@
+2011-11-13 [colin] 3.7.10cvs85
+
+ * src/compose.c
+ Make compose windows printable
+
2011-11-11 [colin] 3.7.10cvs84
* configure.ac
diff --git a/PATCHSETS b/PATCHSETS
@@ -4288,3 +4288,4 @@
( cvs diff -u -r 1.204.2.204 -r 1.204.2.205 src/prefs_common.c; ) > 3.7.10cvs82.patchset
( cvs diff -u -r 1.274.2.335 -r 1.274.2.336 src/mainwindow.c; cvs diff -u -r 1.83.2.179 -r 1.83.2.180 src/mimeview.c; cvs diff -u -r 1.20.2.34 -r 1.20.2.35 src/mimeview.h; cvs diff -u -r 1.395.2.437 -r 1.395.2.438 src/summaryview.c; ) > 3.7.10cvs83.patchset
( cvs diff -u -r 1.654.2.4364 -r 1.654.2.4365 configure.ac; ) > 3.7.10cvs84.patchset
+( cvs diff -u -r 1.382.2.593 -r 1.382.2.594 src/compose.c; ) > 3.7.10cvs85.patchset
diff --git a/configure.ac b/configure.ac
@@ -12,7 +12,7 @@ MINOR_VERSION=7
MICRO_VERSION=10
INTERFACE_AGE=0
BINARY_AGE=0
-EXTRA_VERSION=84
+EXTRA_VERSION=85
EXTRA_RELEASE=
EXTRA_GTK2_VERSION=
diff --git a/src/compose.c b/src/compose.c
@@ -381,6 +381,8 @@ static void compose_insert_sig_cb (GtkAction *action,
static void compose_close_cb (GtkAction *action,
gpointer data);
+static void compose_print_cb (GtkAction *action,
+ gpointer data);
static void compose_set_encoding_cb (GtkAction *action, GtkRadioAction *current, gpointer data);
@@ -569,6 +571,8 @@ static GtkActionEntry compose_entries[] =
/* {"Message/---", NULL, "---" }, */
{"Message/Save", NULL, N_("_Save"), "<control>S", NULL, G_CALLBACK(compose_save_cb) }, /*COMPOSE_KEEP_EDITING*/
/* {"Message/---", NULL, "---" }, */
+ {"Message/Print", NULL, N_("_Print"), NULL, NULL, G_CALLBACK(compose_print_cb) },
+ /* {"Message/---", NULL, "---" }, */
{"Message/Close", NULL, N_("_Close"), "<control>W", NULL, G_CALLBACK(compose_close_cb) },
/* Edit menu */
@@ -7191,6 +7195,8 @@ static Compose *compose_create(PrefsAccount *account,
MENUITEM_ADDUI_MANAGER(compose->ui_manager, "/Menu/Message", "Separator2", "Message/---", GTK_UI_MANAGER_SEPARATOR)
MENUITEM_ADDUI_MANAGER(compose->ui_manager, "/Menu/Message", "Save", "Message/Save", GTK_UI_MANAGER_MENUITEM)
MENUITEM_ADDUI_MANAGER(compose->ui_manager, "/Menu/Message", "Separator3", "Message/---", GTK_UI_MANAGER_SEPARATOR)
+ MENUITEM_ADDUI_MANAGER(compose->ui_manager, "/Menu/Message", "Print", "Message/Print", GTK_UI_MANAGER_MENUITEM)
+ MENUITEM_ADDUI_MANAGER(compose->ui_manager, "/Menu/Message", "Separator4", "Message/---", GTK_UI_MANAGER_SEPARATOR)
MENUITEM_ADDUI_MANAGER(compose->ui_manager, "/Menu/Message", "Close", "Message/Close", GTK_UI_MANAGER_MENUITEM)
/* Edit menu */
@@ -9821,6 +9827,15 @@ static void compose_close_cb(GtkAction *action, gpointer data)
compose_close(compose);
}
+static void compose_print_cb(GtkAction *action, gpointer data)
+{
+ Compose *compose = (Compose *) data;
+
+ compose_draft((gpointer)compose, COMPOSE_AUTO_SAVE);
+ if (compose->targetinfo)
+ messageview_print(compose->targetinfo, FALSE, -1, -1, 0);
+}
+
static void compose_set_encoding_cb(GtkAction *action, GtkRadioAction *current, gpointer data)
{
gboolean active = gtk_toggle_action_get_active (GTK_TOGGLE_ACTION (current));