r2789 - in /unstable/evolution/debian: changelog patches/0001-Move-em_utils_prompt_user-to-e-util-to-remove-duplic.patch patches/0002-EHTMLEditorView-Add-a-checkbox-to-remember-the-choic.patch patches/series

laney at users.alioth.debian.org laney at users.alioth.debian.org
Tue Sep 1 12:50:39 UTC 2015


Author: laney
Date: Tue Sep  1 12:50:39 2015
New Revision: 2789

URL: http://svn.debian.org/wsvn/pkg-evolution/?sc=1&rev=2789
Log:
Cherry-picks from upstream to allow the "Lose formatting?" dialog to be disabled. (Closes: #793209)

Added:
    unstable/evolution/debian/patches/0001-Move-em_utils_prompt_user-to-e-util-to-remove-duplic.patch
    unstable/evolution/debian/patches/0002-EHTMLEditorView-Add-a-checkbox-to-remember-the-choic.patch
Modified:
    unstable/evolution/debian/changelog
    unstable/evolution/debian/patches/series

Modified: unstable/evolution/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-evolution/unstable/evolution/debian/changelog?rev=2789&op=diff
==============================================================================
--- unstable/evolution/debian/changelog	(original)
+++ unstable/evolution/debian/changelog	Tue Sep  1 12:50:39 2015
@@ -10,6 +10,10 @@
   * New upstream release 3.16.5
   * Bump Build-Deps and Deps to ≥ 3.16.5
   * debian/patches/01-gtk-version: Drop, it's in this version
+  * d/p/{0001-Move-em_utils_prompt_user-to-e-util-to-remove-duplic.patch,
+    0002-EHTMLEditorView-Add-a-checkbox-to-remember-the-choic.patch}:
+    Cherry-picks from upstream to allow the "Lose formatting?" dialog to be
+    disabled. (Closes: #793209)
 
  -- Emilio Pozuelo Monfort <pochu at debian.org>  Sat, 13 Jun 2015 02:02:23 +0200
 

Added: unstable/evolution/debian/patches/0001-Move-em_utils_prompt_user-to-e-util-to-remove-duplic.patch
URL: http://svn.debian.org/wsvn/pkg-evolution/unstable/evolution/debian/patches/0001-Move-em_utils_prompt_user-to-e-util-to-remove-duplic.patch?rev=2789&op=file
==============================================================================
--- unstable/evolution/debian/patches/0001-Move-em_utils_prompt_user-to-e-util-to-remove-duplic.patch	(added)
+++ unstable/evolution/debian/patches/0001-Move-em_utils_prompt_user-to-e-util-to-remove-duplic.patch	Tue Sep  1 12:50:39 2015
@@ -0,0 +1,429 @@
+From 2b9ac3f621d1fe8fe49cb1d2d5217d10baefdcb3 Mon Sep 17 00:00:00 2001
+From: Tomas Popela <tpopela at redhat.com>
+Date: Thu, 19 Mar 2015 09:08:12 +0100
+Subject: [PATCH] Move em_utils_prompt_user to e-util to remove duplication
+ from composer
+Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=793209
+
+---
+ composer/e-composer-actions.c            | 57 +------------------------
+ e-util/e-misc-utils.c                    | 68 ++++++++++++++++++++++++++++++
+ e-util/e-misc-utils.h                    |  5 +++
+ mail/e-mail-backend.c                    |  4 +-
+ mail/e-mail-reader-utils.c               | 12 +++---
+ mail/em-composer-utils.c                 | 16 ++++---
+ mail/em-utils.c                          | 72 ++------------------------------
+ mail/em-utils.h                          |  1 -
+ modules/mail/e-mail-shell-view-actions.c |  3 +-
+ 9 files changed, 99 insertions(+), 139 deletions(-)
+
+diff --git a/composer/e-composer-actions.c b/composer/e-composer-actions.c
+index 4a072e3..e7c5524 100644
+--- a/composer/e-composer-actions.c
++++ b/composer/e-composer-actions.c
+@@ -27,59 +27,6 @@
+ #include <errno.h>
+ #include <fcntl.h>
+ 
+-/* because 'composer' is compiled before 'mail' folder */
+-static gboolean
+-composer_copy_em_utils_prompt_user (GtkWindow *parent,
+-				    const gchar *promptkey,
+-				    const gchar *tag,
+-				    ...)
+-{
+-	GtkWidget *dialog;
+-	GtkWidget *check = NULL;
+-	GtkWidget *container;
+-	va_list ap;
+-	gint button;
+-	GSettings *settings;
+-	EAlert *alert = NULL;
+-
+-	settings = e_util_ref_settings ("org.gnome.evolution.mail");
+-
+-	if (promptkey && !g_settings_get_boolean (settings, promptkey)) {
+-		g_object_unref (settings);
+-		return TRUE;
+-	}
+-
+-	va_start (ap, tag);
+-	alert = e_alert_new_valist (tag, ap);
+-	va_end (ap);
+-
+-	dialog = e_alert_dialog_new (parent, alert);
+-	g_object_unref (alert);
+-
+-	container = e_alert_dialog_get_content_area (E_ALERT_DIALOG (dialog));
+-
+-	if (promptkey) {
+-		check = gtk_check_button_new_with_mnemonic (
+-			_("_Do not show this message again"));
+-		gtk_box_pack_start (
+-			GTK_BOX (container), check, FALSE, FALSE, 0);
+-		gtk_widget_show (check);
+-	}
+-
+-	button = gtk_dialog_run (GTK_DIALOG (dialog));
+-	if (promptkey)
+-		g_settings_set_boolean (
+-			settings, promptkey,
+-			!gtk_toggle_button_get_active (
+-				GTK_TOGGLE_BUTTON (check)));
+-
+-	gtk_widget_destroy (dialog);
+-
+-	g_object_unref (settings);
+-
+-	return button == GTK_RESPONSE_YES;
+-}
+-
+ static void
+ action_attach_cb (GtkAction *action,
+                   EMsgComposer *composer)
+@@ -366,8 +313,8 @@ composer_actions_accel_activate_cb (GtkAccelGroup *accel_group,
+ 	EMsgComposer *composer = user_data;
+ 
+ 	if (keyval == GDK_KEY_Return && (modifier & GDK_MODIFIER_MASK) == GDK_CONTROL_MASK &&
+-	    !composer_copy_em_utils_prompt_user (GTK_WINDOW (composer), "prompt-on-accel-send",
+-		"mail-composer:prompt-accel-send", NULL)) {
++	    !e_util_prompt_user (GTK_WINDOW (composer), "org.gnome.evolution.mail",
++		"prompt-on-accel-send", "mail-composer:prompt-accel-send", NULL)) {
+ 		return TRUE;
+ 	}
+ 	return FALSE;
+diff --git a/e-util/e-misc-utils.c b/e-util/e-misc-utils.c
+index da035de..b488394 100644
+--- a/e-util/e-misc-utils.c
++++ b/e-util/e-misc-utils.c
+@@ -49,6 +49,7 @@
+ #include <camel/camel.h>
+ #include <libedataserver/libedataserver.h>
+ 
++#include "e-alert-dialog.h"
+ #include "e-alert-sink.h"
+ #include "e-client-cache.h"
+ #include "e-filter-option.h"
+@@ -3075,3 +3076,70 @@ e_util_cleanup_settings (void)
+ 
+ 	g_mutex_unlock (&settings_hash_lock);
+ }
++
++/**
++ * e_util_prompt_user:
++ * @parent: parent window
++ * @settings_schema: name of the settings schema where @promptkey belongs.
++ * @promptkey: settings key to check if we should prompt the user or not.
++ * @tag: e_alert tag.
++ *
++ * Convenience function to query the user with a Yes/No dialog and a
++ * "Do not show this dialog again" checkbox. If the user checks that
++ * checkbox, then @promptkey is set to %FALSE, otherwise it is set to
++ * %TRUE.
++ *
++ * Returns %TRUE if the user clicks Yes or %FALSE otherwise.
++ **/
++gboolean
++e_util_prompt_user (GtkWindow *parent,
++                    const gchar *settings_schema,
++                    const gchar *promptkey,
++                    const gchar *tag,
++                    ...)
++{
++	GtkWidget *dialog;
++	GtkWidget *check = NULL;
++	GtkWidget *container;
++	va_list ap;
++	gint button;
++	GSettings *settings;
++	EAlert *alert = NULL;
++
++	settings = e_util_ref_settings (settings_schema);
++
++	if (promptkey && !g_settings_get_boolean (settings, promptkey)) {
++		g_object_unref (settings);
++		return TRUE;
++	}
++
++	va_start (ap, tag);
++	alert = e_alert_new_valist (tag, ap);
++	va_end (ap);
++
++	dialog = e_alert_dialog_new (parent, alert);
++	g_object_unref (alert);
++
++	container = e_alert_dialog_get_content_area (E_ALERT_DIALOG (dialog));
++
++	if (promptkey) {
++		check = gtk_check_button_new_with_mnemonic (
++			_("_Do not show this message again"));
++		gtk_box_pack_start (
++			GTK_BOX (container), check, FALSE, FALSE, 0);
++		gtk_widget_show (check);
++	}
++
++	button = gtk_dialog_run (GTK_DIALOG (dialog));
++	if (promptkey)
++		g_settings_set_boolean (
++			settings, promptkey,
++			!gtk_toggle_button_get_active (
++				GTK_TOGGLE_BUTTON (check)));
++
++	gtk_widget_destroy (dialog);
++
++	g_object_unref (settings);
++
++	return button == GTK_RESPONSE_YES;
++}
+diff --git a/e-util/e-misc-utils.h b/e-util/e-misc-utils.h
+index 1d9d016..78146ce 100644
+--- a/e-util/e-misc-utils.h
++++ b/e-util/e-misc-utils.h
+@@ -272,6 +272,11 @@ void		e_signal_disconnect_notify_handler
+ 
+ GSettings *	e_util_ref_settings		(const gchar *schema_id);
+ void		e_util_cleanup_settings		(void);
++gboolean	e_util_prompt_user		(GtkWindow *parent,
++						 const gchar *settings_schema,
++						 const gchar *promptkey,
++						 const gchar *tag,
++						 ...);
+ 
+ G_END_DECLS
+ 
+diff --git a/mail/e-mail-backend.c b/mail/e-mail-backend.c
+index beb5eef..cfe28a6 100644
+--- a/mail/e-mail-backend.c
++++ b/mail/e-mail-backend.c
+@@ -211,8 +211,8 @@ mail_backend_prepare_for_offline_cb (EShell *shell,
+ 			mail_backend_any_store_requires_downsync (account_store);
+ 
+ 		if (ask_to_synchronize) {
+-			synchronize = em_utils_prompt_user (
+-				window, NULL, "mail:ask-quick-offline", NULL);
++			synchronize = e_util_prompt_user (
++				window, "org.gnome.evolution.mail", NULL, "mail:ask-quick-offline", NULL);
+ 		}
+ 
+ 		if (!synchronize) {
+diff --git a/mail/e-mail-reader-utils.c b/mail/e-mail-reader-utils.c
+index 42dcf4b..0df7af1 100644
+--- a/mail/e-mail-reader-utils.c
++++ b/mail/e-mail-reader-utils.c
+@@ -443,8 +443,8 @@ e_mail_reader_expunge_folder (EMailReader *reader,
+ 	window = e_mail_reader_get_window (reader);
+ 	display_name = camel_folder_get_display_name (folder);
+ 
+-	proceed = em_utils_prompt_user (
+-		window, "prompt-on-expunge",
++	proceed = e_util_prompt_user (
++		window, "org.gnome.evolution.mail", "prompt-on-expunge",
+ 		"mail:ask-expunge", display_name, NULL);
+ 
+ 	if (proceed) {
+@@ -1511,8 +1511,8 @@ mail_reader_remove_duplicates_cb (GObject *source_object,
+ 	n_duplicates = g_hash_table_size (duplicates);
+ 
+ 	if (n_duplicates == 0) {
+-		em_utils_prompt_user (
+-			parent_window, NULL,
++		e_util_prompt_user (
++			parent_window, "org.gnome.evolution.mail", NULL,
+ 			"mail:info-no-remove-duplicates",
+ 			camel_folder_get_display_name (folder), NULL);
+ 	} else {
+@@ -1530,8 +1530,8 @@ mail_reader_remove_duplicates_cb (GObject *source_object,
+ 			camel_folder_get_display_name (folder),
+ 			n_duplicates);
+ 
+-		proceed = em_utils_prompt_user (
+-			parent_window, NULL,
++		proceed = e_util_prompt_user (
++			parent_window, "org.gnome.evolution.mail", NULL,
+ 			"mail:ask-remove-duplicates",
+ 			confirmation, NULL);
+ 
+diff --git a/mail/em-composer-utils.c b/mail/em-composer-utils.c
+index 8e5212b..4874995 100644
+--- a/mail/em-composer-utils.c
++++ b/mail/em-composer-utils.c
+@@ -129,9 +129,9 @@ ask_confirm_for_unwanted_html_mail (EMsgComposer *composer,
+ 	}
+ 
+ 	if (str->len)
+-		res = em_utils_prompt_user (
++		res = e_util_prompt_user (
+ 			GTK_WINDOW (composer),
+-			"prompt-on-unwanted-html",
++			"prompt-on-unwanted-html", "org.gnome.evolution.mail",
+ 			"mail:ask-send-html", str->str, NULL);
+ 	else
+ 		res = TRUE;
+@@ -144,8 +144,9 @@ ask_confirm_for_unwanted_html_mail (EMsgComposer *composer,
+ static gboolean
+ ask_confirm_for_empty_subject (EMsgComposer *composer)
+ {
+-	return em_utils_prompt_user (
++	return e_util_prompt_user (
+ 		GTK_WINDOW (composer),
++		"org.gnome.evolution.mail",
+ 		"prompt-on-empty-subject",
+ 		"mail:ask-send-no-subject", NULL);
+ }
+@@ -160,8 +161,9 @@ ask_confirm_for_only_bcc (EMsgComposer *composer,
+ 	 * this dialog to provide slightly different text in that case, to
+ 	 * better explain what the hell is going on. */
+ 
+-	return em_utils_prompt_user (
++	return e_util_prompt_user (
+ 		GTK_WINDOW (composer),
++		"org.gnome.evolution.mail",
+ 		"prompt-on-only-bcc",
+ 		hidden_list_case ?
+ 		"mail:ask-send-only-bcc-contact" :
+@@ -306,8 +308,9 @@ composer_presend_check_recipients (EMsgComposer *composer,
+ 	}
+ 
+ 	if (invalid_addrs) {
+-		if (!em_utils_prompt_user (
++		if (!e_util_prompt_user (
+ 			GTK_WINDOW (composer),
++			"org.gnome.evolution.mail",
+ 			"prompt-on-invalid-recip",
+ 			strstr (invalid_addrs->str, ", ") ?
+ 				"mail:ask-send-invalid-recip-multi" :
+@@ -381,7 +384,8 @@ composer_presend_check_downloads (EMsgComposer *composer,
+ 	store = e_attachment_view_get_store (view);
+ 
+ 	if (e_attachment_store_get_num_loading (store) > 0) {
+-		if (!em_utils_prompt_user (GTK_WINDOW (composer), NULL,
++		if (!e_util_prompt_user (GTK_WINDOW (composer),
++		    "org.gnome.evolution.mail", NULL,
+ 		    "mail-composer:ask-send-message-pending-download", NULL))
+ 			check_passed = FALSE;
+ 	}
+diff --git a/mail/em-utils.c b/mail/em-utils.c
+index b152359..88b845b 100644
+--- a/mail/em-utils.c
++++ b/mail/em-utils.c
+@@ -75,79 +75,14 @@ em_utils_ask_open_many (GtkWindow *parent,
+ 		"Are you sure you want to open %d message at once?",
+ 		"Are you sure you want to open %d messages at once?",
+ 		how_many), how_many);
+-	proceed = em_utils_prompt_user (
+-		parent, "prompt-on-open-many",
++	proceed = e_util_prompt_user (
++		parent, "org.gnome.evolution.mail", "prompt-on-open-many",
+ 		"mail:ask-open-many", string, NULL);
+ 	g_free (string);
+ 
+ 	return proceed;
+ }
+ 
+-/**
+- * em_utils_prompt_user:
+- * @parent: parent window
+- * @promptkey: settings key to check if we should prompt the user or not.
+- * @tag: e_alert tag.
+- *
+- * Convenience function to query the user with a Yes/No dialog and a
+- * "Do not show this dialog again" checkbox. If the user checks that
+- * checkbox, then @promptkey is set to %FALSE, otherwise it is set to
+- * %TRUE.
+- *
+- * Returns %TRUE if the user clicks Yes or %FALSE otherwise.
+- **/
+-gboolean
+-em_utils_prompt_user (GtkWindow *parent,
+-                      const gchar *promptkey,
+-                      const gchar *tag,
+-                      ...)
+-{
+-	GtkWidget *dialog;
+-	GtkWidget *check = NULL;
+-	GtkWidget *container;
+-	va_list ap;
+-	gint button;
+-	GSettings *settings;
+-	EAlert *alert = NULL;
+-
+-	settings = e_util_ref_settings ("org.gnome.evolution.mail");
+-
+-	if (promptkey && !g_settings_get_boolean (settings, promptkey)) {
+-		g_object_unref (settings);
+-		return TRUE;
+-	}
+-
+-	va_start (ap, tag);
+-	alert = e_alert_new_valist (tag, ap);
+-	va_end (ap);
+-
+-	dialog = e_alert_dialog_new (parent, alert);
+-	g_object_unref (alert);
+-
+-	container = e_alert_dialog_get_content_area (E_ALERT_DIALOG (dialog));
+-
+-	if (promptkey) {
+-		check = gtk_check_button_new_with_mnemonic (
+-			_("_Do not show this message again"));
+-		gtk_box_pack_start (
+-			GTK_BOX (container), check, FALSE, FALSE, 0);
+-		gtk_widget_show (check);
+-	}
+-
+-	button = gtk_dialog_run (GTK_DIALOG (dialog));
+-	if (promptkey)
+-		g_settings_set_boolean (
+-			settings, promptkey,
+-			!gtk_toggle_button_get_active (
+-				GTK_TOGGLE_BUTTON (check)));
+-
+-	gtk_widget_destroy (dialog);
+-
+-	g_object_unref (settings);
+-
+-	return button == GTK_RESPONSE_YES;
+-}
+-
+ /* Editing Filters/Search Folders... */
+ 
+ static GtkWidget *filter_editor = NULL;
+@@ -1332,7 +1267,8 @@ em_utils_empty_trash (GtkWidget *parent,
+ 
+ 	registry = e_mail_session_get_registry (session);
+ 
+-	if (!em_utils_prompt_user ((GtkWindow *) parent,
++	if (!e_util_prompt_user ((GtkWindow *) parent,
++		"org.gnome.evolution.mail",
+ 		"prompt-on-empty-trash",
+ 		"mail:ask-empty-trash", NULL))
+ 		return;
+diff --git a/mail/em-utils.h b/mail/em-utils.h
+index ccd4f71..8911cd7 100644
+--- a/mail/em-utils.h
++++ b/mail/em-utils.h
+@@ -36,7 +36,6 @@ G_BEGIN_DECLS
+ struct _EMailPartList;
+ 
+ gboolean em_utils_ask_open_many (GtkWindow *parent, gint how_many);
+-gboolean em_utils_prompt_user (GtkWindow *parent, const gchar *promptkey, const gchar *tag, ...);
+ 
+ void		em_utils_edit_filters		(EMailSession *session,
+ 						 EAlertSink *alert_sink,
+diff --git a/modules/mail/e-mail-shell-view-actions.c b/modules/mail/e-mail-shell-view-actions.c
+index 5852101..6c6540d 100644
+--- a/modules/mail/e-mail-shell-view-actions.c
++++ b/modules/mail/e-mail-shell-view-actions.c
+@@ -588,7 +588,8 @@ mark_all_read_prompt_user (EMailShellView *mail_shell_view,
+ 			default:
+ 				break;
+ 		}
+-	} else if (em_utils_prompt_user (parent,
++	} else if (e_util_prompt_user (parent,
++			"org.gnome.evolution.mail",
+ 			"prompt-on-mark-all-read",
+ 			"mail:ask-mark-all-read", NULL))
+ 		return MARK_ALL_READ_CURRENT_ONLY;
+-- 
+2.5.0
+

Added: unstable/evolution/debian/patches/0002-EHTMLEditorView-Add-a-checkbox-to-remember-the-choic.patch
URL: http://svn.debian.org/wsvn/pkg-evolution/unstable/evolution/debian/patches/0002-EHTMLEditorView-Add-a-checkbox-to-remember-the-choic.patch?rev=2789&op=file
==============================================================================
--- unstable/evolution/debian/patches/0002-EHTMLEditorView-Add-a-checkbox-to-remember-the-choic.patch	(added)
+++ unstable/evolution/debian/patches/0002-EHTMLEditorView-Add-a-checkbox-to-remember-the-choic.patch	Tue Sep  1 12:50:39 2015
@@ -0,0 +1,98 @@
+From 96a4ac56526bf6b0bdb9bb5765acfb7e9280384a Mon Sep 17 00:00:00 2001
+From: Tomas Popela <tpopela at redhat.com>
+Date: Mon, 23 Mar 2015 10:18:37 +0100
+Subject: [PATCH] EHTMLEditorView - Add a checkbox to remember the choice when
+ asking if lose formatting
+Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=793209
+
+---
+ composer/mail-composer.error.xml             |  7 +++++++
+ data/org.gnome.evolution.mail.gschema.xml.in |  5 +++++
+ e-util/e-html-editor-view.c                  | 26 ++++++--------------------
+ 3 files changed, 18 insertions(+), 20 deletions(-)
+
+diff --git a/composer/mail-composer.error.xml b/composer/mail-composer.error.xml
+index 06d4d42..8b9db2d 100644
+--- a/composer/mail-composer.error.xml
++++ b/composer/mail-composer.error.xml
+@@ -102,4 +102,11 @@
+   <button _label="_Send" response="GTK_RESPONSE_YES"/>
+  </error>
+ 
++  <error id="prompt-composer-mode-switch" type="question" default="GTK_RESPONSE_YES">
++  <_primary>Are you sure you want to change the composer mode?</_primary>
++  <_secondary xml:space="preserve">Turning HTML mode off will cause the text to lose all formatting. Do you want to continue?</_secondary>
++  <button _label="_Don't lose formatting" response="GTK_RESPONSE_NO"/>
++  <button _label="Lose _formatting" response="GTK_RESPONSE_YES"/>
++ </error>
++
+ </error-list>
+diff --git a/data/org.gnome.evolution.mail.gschema.xml.in b/data/org.gnome.evolution.mail.gschema.xml.in
+index 89373bb..9cc4c3a 100644
+--- a/data/org.gnome.evolution.mail.gschema.xml.in
++++ b/data/org.gnome.evolution.mail.gschema.xml.in
+@@ -456,6 +456,11 @@
+       <_summary>Prompt when replying to many recipients</_summary>
+       <_description>It disables/enables the repeated prompts to warn that you are sending a reply to many people.</_description>
+     </key>
++    <key name="prompt-on-composer-mode-switch" type="b">
++      <default>true</default>
++      <_summary>Prompt when switching composer mode and the content needs to lose its formatting</_summary>
++      <_description>It disables/enables the repeated prompts to warn that you are switching composer mode and the content needs to lose its formatting.</_description>
++    </key>
+     <key name="browser-close-on-reply-policy" enum="org.gnome.evolution.mail.AutomaticActionPolicy">
+       <default>'ask'</default>
+       <_summary>Policy for automatically closing the message browser window when forwarding or replying to the displayed message.</_summary>
+diff --git a/e-util/e-html-editor-view.c b/e-util/e-html-editor-view.c
+index a9e3310..a84dc78 100644
+--- a/e-util/e-html-editor-view.c
++++ b/e-util/e-html-editor-view.c
+@@ -8686,8 +8686,8 @@ process_content_for_html (EHTMLEditorView *view)
+ static gboolean
+ show_lose_formatting_dialog (EHTMLEditorView *view)
+ {
+-	gint result;
+-	GtkWidget *toplevel, *dialog;
++	gboolean lose;
++	GtkWidget *toplevel;
+ 	GtkWindow *parent = NULL;
+ 
+ 	toplevel = gtk_widget_get_toplevel (GTK_WIDGET (view));
+@@ -8695,30 +8695,16 @@ show_lose_formatting_dialog (EHTMLEditorView *view)
+ 	if (GTK_IS_WINDOW (toplevel))
+ 		parent = GTK_WINDOW (toplevel);
+ 
+-	dialog = gtk_message_dialog_new (
+-		parent,
+-		GTK_DIALOG_DESTROY_WITH_PARENT,
+-		GTK_MESSAGE_WARNING,
+-		GTK_BUTTONS_NONE,
+-		_("Turning HTML mode off will cause the text "
+-		"to lose all formatting. Do you want to continue?"));
+-	gtk_dialog_add_buttons (
+-		GTK_DIALOG (dialog),
+-		_("_Don't lose formatting"), GTK_RESPONSE_CANCEL,
+-		_("_Lose formatting"), GTK_RESPONSE_OK,
+-		NULL);
+-
+-	result = gtk_dialog_run (GTK_DIALOG (dialog));
++	lose = e_util_prompt_user (
++		parent, "org.gnome.evolution.mail", "prompt-on-composer-mode-switch",
++		"mail-composer:prompt-composer-mode-switch", NULL);
+ 
+-	if (result != GTK_RESPONSE_OK) {
+-		gtk_widget_destroy (dialog);
++	if (!lose) {
+ 		/* Nothing has changed, but notify anyway */
+ 		g_object_notify (G_OBJECT (view), "html-mode");
+ 		return FALSE;
+ 	}
+ 
+-	gtk_widget_destroy (dialog);
+-
+ 	return TRUE;
+ }
+ 
+-- 
+2.5.0
+

Modified: unstable/evolution/debian/patches/series
URL: http://svn.debian.org/wsvn/pkg-evolution/unstable/evolution/debian/patches/series?rev=2789&op=diff
==============================================================================
--- unstable/evolution/debian/patches/series	(original)
+++ unstable/evolution/debian/patches/series	Tue Sep  1 12:50:39 2015
@@ -1,2 +1,4 @@
+0001-Move-em_utils_prompt_user-to-e-util-to-remove-duplic.patch
+0002-EHTMLEditorView-Add-a-checkbox-to-remember-the-choic.patch
 02_nss_paths.patch
 10_revert_libevolution_avoid-version.patch




More information about the pkg-evolution-commits mailing list