[evince/gnome-3-14] shell: Never save n-copies in the print-settings file
- From: Jose Aliste <jaliste src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evince/gnome-3-14] shell: Never save n-copies in the print-settings file
- Date: Tue, 28 Apr 2015 10:30:32 +0000 (UTC)
commit 9f8c4cafcb34a14913ea18a3043e3a56305a266d
Author: José Aliste <jaliste src gnome org>
Date: Tue Apr 28 00:07:54 2015 -0300
shell: Never save n-copies in the print-settings file
By default gtk_print_settings_to_key_file save all settings. When fixing
https://bugzilla.gnome.org/show_bug.cgi?id=696203 we re-introduced
https://bugzilla.gnome.org/show_bug.cgi?id=488806 for the number of copies.
This happens because the code that saves the document print settings in the evince
metadata deletes the document print settings from the key file. Thus,
the fix for bug #696203 is not stricty correct because we still
need to delete n-copies from the key_file. This patch fixes that.
https://bugzilla.gnome.org/show_bug.cgi?id=748549
shell/ev-window.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/shell/ev-window.c b/shell/ev-window.c
index a16f775..b949452 100644
--- a/shell/ev-window.c
+++ b/shell/ev-window.c
@@ -3079,6 +3079,9 @@ ev_window_save_print_settings (EvWindow *window,
key_file = get_print_settings_file ();
gtk_print_settings_to_key_file (print_settings, key_file, EV_PRINT_SETTINGS_GROUP);
+ /* Always Remove n_copies from global settings */
+ g_key_file_remove_key (key_file, EV_PRINT_SETTINGS_GROUP, GTK_PRINT_SETTINGS_N_COPIES, NULL);
+
/* Save print settings that are specific to the document */
for (i = 0; i < G_N_ELEMENTS (document_print_settings); i++) {
/* Remove it from global settings */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]