Merge lp:~larsu/evince/drop-gtk-310-hacks into lp:~ubuntu-desktop/evince/ubuntu

Proposed by Lars Karlitski on 2014-07-15
Status: Rejected
Rejected by: Sebastien Bacher on 2014-09-15
Proposed branch: lp:~larsu/evince/drop-gtk-310-hacks
Merge into: lp:~ubuntu-desktop/evince/ubuntu
Diff against target: 314 lines (+8/-281)
4 files modified
debian/changelog (+8/-0)
debian/patches/0002-Don-t-use-gtk_application_set_accels_for_action.patch (+0/-193)
debian/patches/gtk310-secondary-keybindings.patch (+0/-86)
debian/patches/series (+0/-2)
To merge this branch: bzr merge lp:~larsu/evince/drop-gtk-310-hacks
Reviewer Review Type Date Requested Status
Sebastien Bacher 2014-07-15 Approve on 2014-09-15
Review via email: mp+226786@code.launchpad.net

Commit message

* debian/patches/0002-Don-t-use-gtk_application_set_accels_for_action.patch,
  debian/patches/gtk310-secondary-keybindings.patch:
  - drop those patches as gtk 3.12 doesn't need those hacks anymore

Description of the change

* debian/patches/0002-Don-t-use-gtk_application_set_accels_for_action.patch,
  debian/patches/gtk310-secondary-keybindings.patch:
  - drop those patches as gtk 3.12 doesn't need those hacks anymore

To post a comment you must log in.
Sebastien Bacher (seb128) wrote :

Thanks, we update evince to 3.13 which included cleaning out those changes

review: Approve

Unmerged revisions

247. By Lars Karlitski on 2014-07-15

* debian/patches/0002-Don-t-use-gtk_application_set_accels_for_action.patch,
  debian/patches/gtk310-secondary-keybindings.patch:
  - drop those patches as gtk 3.12 doesn't need those hacks anymore

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'debian/changelog'
2--- debian/changelog 2014-06-06 19:05:36 +0000
3+++ debian/changelog 2014-07-15 08:15:31 +0000
4@@ -1,3 +1,11 @@
5+evince (3.10.3-0ubuntu14) UNRELEASED; urgency=medium
6+
7+ * debian/patches/0002-Don-t-use-gtk_application_set_accels_for_action.patch,
8+ debian/patches/gtk310-secondary-keybindings.patch:
9+ - drop those patches as gtk 3.12 doesn't need those hacks anymore
10+
11+ -- Lars Uebernickel <lars.uebernickel@ubuntu.com> Tue, 15 Jul 2014 10:04:45 +0200
12+
13 evince (3.10.3-0ubuntu13) utopic; urgency=medium
14
15 * debian/apparmor-profile.abstraction: allow rw to ~/.config/evince
16
17=== removed file 'debian/patches/0002-Don-t-use-gtk_application_set_accels_for_action.patch'
18--- debian/patches/0002-Don-t-use-gtk_application_set_accels_for_action.patch 2014-04-29 14:12:21 +0000
19+++ debian/patches/0002-Don-t-use-gtk_application_set_accels_for_action.patch 1970-01-01 00:00:00 +0000
20@@ -1,193 +0,0 @@
21-From 6781213261c36f4f6c417b06da630a49484faab4 Mon Sep 17 00:00:00 2001
22-From: Lars Uebernickel <lars.uebernickel@canonical.com>
23-Date: Mon, 10 Feb 2014 18:13:56 +0100
24-Subject: [PATCH] Don't use gtk_application_set_accels_for_action()
25-
26-Gtk 3.10 doesn't have this function. Change that to use
27-gtk_application_add_accelerator. Also add the accelerators to menus.xml
28-so that they show up in the UI. (It should be enough to only add them to
29-menus.xml, but gtk doesn't seem to pick those up. It's not worth fixing
30-that bug as the accelerator handling is revamped in 3.12 and the this
31-workaround works fine.)
32----
33- shell/ev-application.c | 2 +-
34- shell/menus.ui | 22 ++++++++++++++++++++++
35- 2 files changed, 23 insertions(+), 1 deletion(-)
36-
37-Index: evince-3.10.3/shell/ev-application.c
38-===================================================================
39---- evince-3.10.3.orig/shell/ev-application.c 2014-04-29 16:09:07.319931409 +0200
40-+++ evince-3.10.3/shell/ev-application.c 2014-04-29 16:09:33.031931585 +0200
41-@@ -1193,7 +1193,17 @@
42- it = action_accels;
43- while (it[0])
44- {
45-- gtk_application_set_accels_for_action (GTK_APPLICATION (application), it[0], &it[1]);
46-+ gchar *action;
47-+ GVariant *target;
48-+
49-+ if (g_action_parse_detailed_name (it[0], &action, &target, NULL))
50-+ {
51-+ gtk_application_add_accelerator (GTK_APPLICATION (application), it[1], action, target);
52-+
53-+ g_free (action);
54-+ if (target)
55-+ g_variant_unref (target);
56-+ }
57- it += g_strv_length ((gchar **) it) + 1;
58- }
59- }
60-Index: evince-3.10.3/shell/menus.ui
61-===================================================================
62---- evince-3.10.3.orig/shell/menus.ui 2014-04-29 16:09:07.319931409 +0200
63-+++ evince-3.10.3/shell/menus.ui 2014-04-29 16:09:07.311931409 +0200
64-@@ -23,6 +23,7 @@
65- <item>
66- <attribute name="label" translatable="yes">_Open</attribute>
67- <attribute name="action">app.open</attribute>
68-+ <attribute name="accel">&lt;Ctrl&gt;O</attribute>
69- </item>
70- </section>
71- <section>
72-@@ -33,6 +34,7 @@
73- <item>
74- <attribute name="label" translatable="yes">_Help</attribute>
75- <attribute name="action">app.help</attribute>
76-+ <attribute name="accel">F1</attribute>
77- </item>
78- </section>
79- </menu>
80-@@ -52,36 +54,43 @@
81- <item>
82- <attribute name="label" translatable="yes">Side _Pane</attribute>
83- <attribute name="action">win.show-side-pane</attribute>
84-+ <attribute name="accel">F9</attribute>
85- </item>
86- </section>
87- <section>
88- <item>
89- <attribute name="label" translatable="yes">_Fullscreen</attribute>
90- <attribute name="action">win.fullscreen</attribute>
91-+ <attribute name="accel">F11</attribute>
92- </item>
93- <item>
94- <attribute name="label" translatable="yes">Pre_sentation</attribute>
95- <attribute name="action">win.presentation</attribute>
96-+ <attribute name="accel">F5</attribute>
97- </item>
98- </section>
99- <section>
100- <item>
101- <attribute name="label" translatable="yes">Rotate _Left</attribute>
102- <attribute name="action">win.rotate-left</attribute>
103-+ <attribute name="accel">&lt;Ctrl&gt;Left</attribute>
104- </item>
105- <item>
106- <attribute name="label" translatable="yes">Rotate _Right</attribute>
107- <attribute name="action">win.rotate-right</attribute>
108-+ <attribute name="accel">&lt;Ctrl&gt;Right</attribute>
109- </item>
110- </section>
111- <section>
112- <item>
113- <attribute name="label" translatable="yes">Zoom _In</attribute>
114- <attribute name="action">win.zoom-in</attribute>
115-+ <attribute name="accel">&lt;Ctrl&gt;plus</attribute>
116- </item>
117- <item>
118- <attribute name="label" translatable="yes">Zoom _Out</attribute>
119- <attribute name="action">win.zoom-out</attribute>
120-+ <attribute name="accel">&lt;Ctrl&gt;minus</attribute>
121- </item>
122- </section>
123- <section>
124-@@ -92,12 +101,14 @@
125- <item>
126- <attribute name="label" translatable="yes">_Inverted Colors</attribute>
127- <attribute name="action">win.inverted-colors</attribute>
128-+ <attribute name="accel">&lt;Ctrl&gt;I</attribute>
129- </item>
130- </section>
131- <section>
132- <item>
133- <attribute name="label" translatable="yes">_Reload</attribute>
134- <attribute name="action">win.reload</attribute>
135-+ <attribute name="accel">&lt;Ctrl&gt;R</attribute>
136- </item>
137- </section>
138- </menu>
139-@@ -107,10 +118,12 @@
140- <item>
141- <attribute name="label" translatable="yes">_Open…</attribute>
142- <attribute name="action">app.open</attribute>
143-+ <attribute name="accel">&lt;Ctrl&gt;O</attribute>
144- </item>
145- <item>
146- <attribute name="label" translatable="yes">Op_en a Copy</attribute>
147- <attribute name="action">win.open-copy</attribute>
148-+ <attribute name="accel">&lt;Ctrl&gt;N</attribute>
149- </item>
150- <item>
151- <attribute name="label" translatable="yes">_Recent</attribute>
152-@@ -120,6 +133,7 @@
153- <item>
154- <attribute name="label" translatable="yes">_Save a Copy…</attribute>
155- <attribute name="action">win.save-copy</attribute>
156-+ <attribute name="accel">&lt;Ctrl&gt;S</attribute>
157- </item>
158- <item>
159- <attribute name="label" translatable="yes">Send _To…</attribute>
160-@@ -132,22 +146,26 @@
161- <item>
162- <attribute name="label" translatable="yes">_Print…</attribute>
163- <attribute name="action">win.print</attribute>
164-+ <attribute name="accel">&lt;Ctrl&gt;P</attribute>
165- </item>
166- </section>
167- <section>
168- <item>
169- <attribute name="label" translatable="yes">P_roperties…</attribute>
170- <attribute name="action">win.show-properties</attribute>
171-+ <attribute name="accel">&lt;Alt&gt;Return</attribute>
172- </item>
173- </section>
174- <section>
175- <item>
176- <attribute name="label" translatable="yes">_Copy</attribute>
177- <attribute name="action">win.copy</attribute>
178-+ <attribute name="accel">&lt;Ctrl&gt;C</attribute>
179- </item>
180- <item>
181- <attribute name="label" translatable="yes">Select _All</attribute>
182- <attribute name="action">win.select-all</attribute>
183-+ <attribute name="accel">&lt;Ctrl&gt;A</attribute>
184- </item>
185- </section>
186- <section>
187-@@ -160,22 +178,26 @@
188- <item>
189- <attribute name="label" translatable="yes">_First Page</attribute>
190- <attribute name="action">win.go-first-page</attribute>
191-+ <attribute name="accel">&lt;Ctrl&gt;Home</attribute>
192- </item>
193- <item>
194- <attribute name="label" translatable="yes">_Last Page</attribute>
195- <attribute name="action">win.go-last-page</attribute>
196-+ <attribute name="accel">&lt;Ctrl&gt;End</attribute>
197- </item>
198- </section>
199- <section id="bookmarks">
200- <item>
201- <attribute name="label" translatable="yes">_Add Bookmark</attribute>
202- <attribute name="action">win.add-bookmark</attribute>
203-+ <attribute name="accel">&lt;Ctrl&gt;D</attribute>
204- </item>
205- </section>
206- <section>
207- <item>
208- <attribute name="label" translatable="yes">_Close</attribute>
209- <attribute name="action">win.close</attribute>
210-+ <attribute name="accel">&lt;Ctrl&gt;W</attribute>
211- </item>
212- </section>
213- <section>
214
215=== removed file 'debian/patches/gtk310-secondary-keybindings.patch'
216--- debian/patches/gtk310-secondary-keybindings.patch 2014-06-03 13:44:50 +0000
217+++ debian/patches/gtk310-secondary-keybindings.patch 1970-01-01 00:00:00 +0000
218@@ -1,86 +0,0 @@
219-From 24c0293b4d520193553d99f1423b9e0394eec0ef Mon Sep 17 00:00:00 2001
220-From: Lars Uebernickel <lars.uebernickel@canonical.com>
221-Date: Tue, 11 Mar 2014 17:00:02 +0100
222-Subject: [PATCH] Add secondary (and tertiary) keybindings
223-
224-gtk_application_add_accelerator() can only add one accel per action.
225-Duplicate the actions so that we can add multiple accels. This is very
226-gross, but only needed until we update to gtk 3.12, which introduces a
227-new function that can handle setting multiple accels for a single
228-action.
229----
230- shell/ev-application.c | 10 ++++++++++
231- shell/ev-window.c | 10 ++++++++++
232- 2 files changed, 20 insertions(+)
233-
234-diff --git a/shell/ev-application.c b/shell/ev-application.c
235-index 4493b1e..65064b1 100644
236---- a/shell/ev-application.c
237-+++ b/shell/ev-application.c
238-@@ -1093,6 +1093,7 @@ ev_application_startup (GApplication *gapplication)
239- "win.save-copy", "<Ctrl>S", NULL,
240- "win.print", "<Ctrl>P", NULL,
241- "win.copy", "<Ctrl>C", "<Ctrl>Insert", NULL,
242-+ "win.copy2", "<Ctrl>Insert", NULL,
243- "win.select-all", "<Ctrl>A", NULL,
244- "win.save-settings", "<Ctrl>T", NULL,
245- "win.go-first-page", "<Ctrl>Home", NULL,
246-@@ -1107,13 +1108,22 @@ ev_application_startup (GApplication *gapplication)
247- "win.go-backward", "<Shift>Page_Up", NULL,
248- "win.go-forward", "<Shift>Page_Down", NULL,
249- "win.go-next-page", "<Ctrl>Page_Down", "n", NULL,
250-+ "win.go-next-page2", "n", NULL,
251- "win.go-previous-page", "<Ctrl>Page_Up", "p", NULL,
252-+ "win.go-previous-page2", "p", NULL,
253- "win.sizing-mode::fit-page", "f", NULL,
254- "win.sizing-mode::fit-width", "w", NULL,
255- "win.open-menu", "F10", NULL,
256- "win.caret-navigation", "F7", NULL,
257- "win.zoom-in", "plus", "<Ctrl>plus", "KP_Add", "<Ctrl>KP_Add", "equal", NULL,
258-+ "win.zoom-in2", "<Ctrl>plus", "KP_Add", "<Ctrl>KP_Add", NULL,
259-+ "win.zoom-in3", "KP_Add", "<Ctrl>KP_Add", NULL,
260-+ "win.zoom-in4", "<Ctrl>KP_Add", NULL,
261-+ "win.zoom-in5", "equal", NULL,
262- "win.zoom-out", "minus", "<Ctrl>minus", "KP_Subtract", "<Ctrl>KP_Subtract", NULL,
263-+ "win.zoom-out2", "<Ctrl>minus", "KP_Subtract", "<Ctrl>KP_Subtract", NULL,
264-+ "win.zoom-out3", "KP_Subtract", "<Ctrl>KP_Subtract", NULL,
265-+ "win.zoom-out4", "<Ctrl>KP_Subtract", NULL,
266- "win.show-side-pane", "F9", NULL,
267- "win.fullscreen", "F11", NULL,
268- "win.presentation", "F5", NULL,
269-diff --git a/shell/ev-window.c b/shell/ev-window.c
270-index fc2258e..9f685fa 100644
271---- a/shell/ev-window.c
272-+++ b/shell/ev-window.c
273-@@ -6658,10 +6658,13 @@ ev_window_init (EvWindow *ev_window)
274- { "print", ev_window_activate_print_action, NULL, NULL, NULL },
275- { "show-properties", ev_window_activate_show_properties_action, NULL, NULL, NULL },
276- { "copy", ev_window_activate_copy_action, NULL, NULL, NULL },
277-+ { "copy2", ev_window_activate_copy_action, NULL, NULL, NULL },
278- { "select-all", ev_window_activate_select_all_action, NULL, NULL, NULL },
279- { "save-settings", ev_window_activate_save_settings_action, NULL, NULL, NULL },
280- { "go-previous-page", ev_window_activate_go_previous_page_action, NULL, NULL, NULL },
281-+ { "go-previous-page2", ev_window_activate_go_previous_page_action, NULL, NULL, NULL },
282- { "go-next-page", ev_window_activate_go_next_page_action, NULL, NULL, NULL },
283-+ { "go-next-page2", ev_window_activate_go_next_page_action, NULL, NULL, NULL },
284- { "go-first-page", ev_window_activate_go_first_page_action, NULL, NULL, NULL },
285- { "go-last-page", ev_window_activate_go_last_page_action, NULL, NULL, NULL },
286- { "go-forward", ev_window_activate_go_forward_action, NULL, NULL, NULL },
287-@@ -6680,7 +6683,14 @@ ev_window_init (EvWindow *ev_window)
288- { "rotate-left", ev_window_activate_rotate_left_action, NULL, NULL, NULL },
289- { "rotate-right", ev_window_activate_rotate_right_action, NULL, NULL, NULL },
290- { "zoom-in", ev_window_activate_zoom_in_action, NULL, NULL, NULL },
291-+ { "zoom-in2", ev_window_activate_zoom_in_action, NULL, NULL, NULL },
292-+ { "zoom-in3", ev_window_activate_zoom_in_action, NULL, NULL, NULL },
293-+ { "zoom-in4", ev_window_activate_zoom_in_action, NULL, NULL, NULL },
294-+ { "zoom-in5", ev_window_activate_zoom_in_action, NULL, NULL, NULL },
295- { "zoom-out", ev_window_activate_zoom_out_action, NULL, NULL, NULL },
296-+ { "zoom-out2", ev_window_activate_zoom_out_action, NULL, NULL, NULL },
297-+ { "zoom-out3", ev_window_activate_zoom_out_action, NULL, NULL, NULL },
298-+ { "zoom-out4", ev_window_activate_zoom_out_action, NULL, NULL, NULL },
299- { "reload", ev_window_activate_reload_action, NULL, NULL, NULL },
300- { "auto-scroll", ev_window_activate_auto_scroll_action, NULL, NULL, NULL },
301- { "add-bookmark", ev_window_activate_add_bookmark_action, NULL, NULL, NULL },
302---
303-1.9.1
304-
305
306=== modified file 'debian/patches/series'
307--- debian/patches/series 2014-03-11 17:35:19 +0000
308+++ debian/patches/series 2014-07-15 08:15:31 +0000
309@@ -1,5 +1,3 @@
310 11_grip_gestures.patch
311 git_Don-t-allow-Send-To-when-there-is-no-mail-client-ava.patch
312 0001-Port-to-GMenuModel-and-add-menu-bar.patch
313-0002-Don-t-use-gtk_application_set_accels_for_action.patch
314-gtk310-secondary-keybindings.patch

Subscribers

People subscribed via source and target branches

to all changes: