From 057ee6b0d904f116c2eab53a7295d8a6d8bb9d9a Mon Sep 17 00:00:00 2001 From: Marek Kasik Date: Mon, 9 Mar 2015 10:56:57 +0100 Subject: [PATCH] Update to 3.14.2 --- .gitignore | 1 + ...ind-action-for-documents-not-support.patch | 26 ---- ...-configuration-with-ligbnome-desktop.patch | 27 ---- ...ical-warning-when-starting-in-fullsc.patch | 36 ------ ...o-the-search-result-selected-by-user.patch | 38 ------ ...Fix-centering-of-documents-when-prin.patch | 122 ------------------ ...iew-Check-whether-load-job-succeeded.patch | 32 ----- ...ge-when-next-search-result-requested.patch | 41 ------ evince.spec | 33 +---- sources | 2 +- 10 files changed, 7 insertions(+), 351 deletions(-) delete mode 100644 0001-Disable-toggle-find-action-for-documents-not-support.patch delete mode 100644 0001-Fix-configuration-with-ligbnome-desktop.patch delete mode 100644 0001-Fix-runtime-critical-warning-when-starting-in-fullsc.patch delete mode 100644 0001-Scroll-to-the-search-result-selected-by-user.patch delete mode 100644 0001-print-operation-Fix-centering-of-documents-when-prin.patch delete mode 100644 0001-recent-view-Check-whether-load-job-succeeded.patch delete mode 100644 0002-Show-correct-page-when-next-search-result-requested.patch diff --git a/.gitignore b/.gitignore index 6e14072..5fd20bf 100644 --- a/.gitignore +++ b/.gitignore @@ -44,3 +44,4 @@ evince-3.0.0.tar.bz2 /evince-3.13.92.tar.xz /evince-3.14.0.tar.xz /evince-3.14.1.tar.xz +/evince-3.14.2.tar.xz diff --git a/0001-Disable-toggle-find-action-for-documents-not-support.patch b/0001-Disable-toggle-find-action-for-documents-not-support.patch deleted file mode 100644 index 708730a..0000000 --- a/0001-Disable-toggle-find-action-for-documents-not-support.patch +++ /dev/null @@ -1,26 +0,0 @@ -From bfa59b72ed0c86192ca9b1f0882ca5119aa7fe12 Mon Sep 17 00:00:00 2001 -From: Carlos Garcia Campos -Date: Sun, 19 Oct 2014 15:24:18 +0200 -Subject: [PATCH] Disable toggle-find action for documents not supporting find - -https://bugzilla.gnome.org/show_bug.cgi?id=738262 ---- - shell/ev-window.c | 2 ++ - 1 file changed, 2 insertions(+) - -diff --git a/shell/ev-window.c b/shell/ev-window.c -index c4f1f5d..4de4732 100644 ---- a/shell/ev-window.c -+++ b/shell/ev-window.c -@@ -502,6 +502,8 @@ ev_window_update_actions_sensitivity (EvWindow *ev_window) - can_get_text && !recent_view_mode); - ev_window_set_action_enabled (ev_window, "find", can_find && - !recent_view_mode); -+ ev_window_set_action_enabled (ev_window, "toggle-find", can_find && -+ !recent_view_mode); - ev_window_set_action_enabled (ev_window, "rotate-left", has_pages && - !recent_view_mode); - ev_window_set_action_enabled (ev_window, "rotate-right", has_pages && --- -2.1.0 - diff --git a/0001-Fix-configuration-with-ligbnome-desktop.patch b/0001-Fix-configuration-with-ligbnome-desktop.patch deleted file mode 100644 index 35a4de4..0000000 --- a/0001-Fix-configuration-with-ligbnome-desktop.patch +++ /dev/null @@ -1,27 +0,0 @@ -From 6709534cdc8824459e805c120c2f74b97670b769 Mon Sep 17 00:00:00 2001 -From: Marek Kasik -Date: Wed, 19 Nov 2014 10:53:29 +0100 -Subject: [PATCH] Fix configuration with ligbnome-desktop - -A typo caused fail of configuration with enabled -support for libgnome-desktop. ---- - configure.ac | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/configure.ac b/configure.ac -index dd4bcab..0ae92b1 100644 ---- a/configure.ac -+++ b/configure.ac -@@ -313,7 +313,7 @@ if test "$enable_gnome_desktop" != "no"; then - PKG_CHECK_MODULES([LIBGNOME_DESKTOP], [gnome-desktop-3.0], has_libgnome_desktop=yes, has_libgnome_desktop=no) - else - PKG_CHECK_MODULES([LIBGNOME_DESKTOP], [gnome-desktop-3.0]) -- has_libgnome_desktop = yes -+ has_libgnome_desktop=yes - fi - - if test x$has_libgnome_desktop = xyes; then --- -2.1.0 - diff --git a/0001-Fix-runtime-critical-warning-when-starting-in-fullsc.patch b/0001-Fix-runtime-critical-warning-when-starting-in-fullsc.patch deleted file mode 100644 index 3c281c2..0000000 --- a/0001-Fix-runtime-critical-warning-when-starting-in-fullsc.patch +++ /dev/null @@ -1,36 +0,0 @@ -From 8875003da7f78a6fbba36fcc70d6ed2d372da7a6 Mon Sep 17 00:00:00 2001 -From: Carlos Garcia Campos -Date: Sun, 19 Oct 2014 16:01:38 +0200 -Subject: [PATCH] Fix runtime critical warning when starting in fullscreen mode - -The problem is that when running fullscreen mode we call -ev_window_update_links_model() to update the page action widget of the -fullscreen toolbar, but when running directly in fullscreen mode, this -can happen before the links have been loaded in the sidebar. Since -ev_window_update_links_model() is also called automatically when the -links model property changes, we can simply return early in -ev_window_update_links_model() when the model is NULL and it will be -called again with a valid model when the links job finishes. - -https://bugzilla.gnome.org/show_bug.cgi?id=737864 ---- - shell/ev-window.c | 3 +++ - 1 file changed, 3 insertions(+) - -diff --git a/shell/ev-window.c b/shell/ev-window.c -index 4de4732..e7f6a96 100644 ---- a/shell/ev-window.c -+++ b/shell/ev-window.c -@@ -4024,6 +4024,9 @@ ev_window_update_links_model (EvWindow *window) - "model", &model, - NULL); - -+ if (!model) -+ return; -+ - page_selector = ev_toolbar_get_page_selector (EV_TOOLBAR (window->priv->toolbar)); - ev_page_action_widget_update_links_model (EV_PAGE_ACTION_WIDGET (page_selector), model); - if (window->priv->fs_toolbar) { --- -2.1.0 - diff --git a/0001-Scroll-to-the-search-result-selected-by-user.patch b/0001-Scroll-to-the-search-result-selected-by-user.patch deleted file mode 100644 index 2159a98..0000000 --- a/0001-Scroll-to-the-search-result-selected-by-user.patch +++ /dev/null @@ -1,38 +0,0 @@ -From 5310e9e9bb7e29490c89e3e53243088d7ce5f518 Mon Sep 17 00:00:00 2001 -From: Marek Kasik -Date: Mon, 19 May 2014 14:32:19 +0200 -Subject: [PATCH 1/2] Scroll to the search result selected by user - -Scroll to page on which is the search result selected by user -when not in continuous mode. - -https://bugzilla.gnome.org/show_bug.cgi?id=730252 ---- - libview/ev-view.c | 4 ++++ - 1 file changed, 4 insertions(+) - -diff --git a/libview/ev-view.c b/libview/ev-view.c -index 5ed2d78..f3aa033 100644 ---- a/libview/ev-view.c -+++ b/libview/ev-view.c -@@ -8158,6 +8158,9 @@ jump_to_find_page (EvView *view, EvViewFindDirection direction, gint shift) - break; - } - } -+ -+ if (!view->continuous) -+ ev_document_model_set_page (view->model, view->find_page); - } - - static void -@@ -8282,6 +8285,7 @@ ev_view_find_set_result (EvView *view, gint page, gint result) - { - view->find_page = page; - view->find_result = result; -+ jump_to_find_page (view, EV_VIEW_FIND_NEXT, 0); - jump_to_find_result (view); - gtk_widget_queue_draw (GTK_WIDGET (view)); - } --- -2.1.0 - diff --git a/0001-print-operation-Fix-centering-of-documents-when-prin.patch b/0001-print-operation-Fix-centering-of-documents-when-prin.patch deleted file mode 100644 index 3f1d957..0000000 --- a/0001-print-operation-Fix-centering-of-documents-when-prin.patch +++ /dev/null @@ -1,122 +0,0 @@ -From ae7a5715131613955a37419b5da1d6d9f3c1cb1d Mon Sep 17 00:00:00 2001 -From: Carlos Garcia Campos -Date: Thu, 14 Aug 2014 14:07:05 +0200 -Subject: [PATCH] print-operation: Fix centering of documents when printing - with a manual scale - -When a manual scale is used for printing, the document is not correctly -centered because the cairo context has a scale already applied. We need -to consider the current scale when centering the page and also convert -the coordinates before the cairo_translate(). - -https://bugzilla.gnome.org/show_bug.cgi?id=734788 ---- - libview/ev-print-operation.c | 60 +++++++++++++++++++++++++++++++------------- - 1 file changed, 42 insertions(+), 18 deletions(-) - -diff --git a/libview/ev-print-operation.c b/libview/ev-print-operation.c -index 8d5aa39..4a268b4 100644 ---- a/libview/ev-print-operation.c -+++ b/libview/ev-print-operation.c -@@ -1825,6 +1825,27 @@ _print_context_get_hard_margins (GtkPrintContext *context, - } - - static void -+ev_print_operation_print_get_scaled_page_size (EvPrintOperationPrint *print, -+ gint page, -+ gdouble *width, -+ gdouble *height) -+{ -+ GtkPrintSettings *settings; -+ gdouble manual_scale; -+ -+ ev_document_get_page_size (EV_PRINT_OPERATION (print)->document, -+ page, width, height); -+ -+ settings = gtk_print_operation_get_print_settings (print->op); -+ manual_scale = gtk_print_settings_get_scale (settings) / 100.0; -+ if (manual_scale == 1.0) -+ return; -+ -+ *width *= manual_scale; -+ *height *= manual_scale; -+} -+ -+static void - ev_print_operation_print_draw_page (EvPrintOperationPrint *print, - GtkPrintContext *context, - gint page) -@@ -1834,6 +1855,7 @@ ev_print_operation_print_draw_page (EvPrintOperationPrint *print, - gdouble cr_width, cr_height; - gdouble width, height, scale; - gdouble x_scale, y_scale; -+ gdouble x_offset, y_offset; - gdouble top, bottom, left, right; - - gtk_print_operation_set_defer_drawing (print->op); -@@ -1857,12 +1879,16 @@ ev_print_operation_print_draw_page (EvPrintOperationPrint *print, - cr = gtk_print_context_get_cairo_context (context); - cr_width = gtk_print_context_get_width (context); - cr_height = gtk_print_context_get_height (context); -- ev_document_get_page_size (op->document, page, &width, &height); -+ ev_print_operation_print_get_scaled_page_size (print, page, &width, &height); - - if (print->page_scale == EV_SCALE_NONE) { - /* Center document page on the printed page */ -- if (print->autorotate) -- cairo_translate (cr, (cr_width - width) / 2, (cr_height - height) / 2); -+ if (print->autorotate) { -+ x_offset = (cr_width - width) / 2; -+ y_offset = (cr_height - height) / 2; -+ cairo_device_to_user (cr, &x_offset, &y_offset); -+ cairo_translate (cr, x_offset, y_offset); -+ } - } else { - _print_context_get_hard_margins (context, &top, &bottom, &left, &right); - -@@ -1875,29 +1901,27 @@ ev_print_operation_print_draw_page (EvPrintOperationPrint *print, - scale = 1.0; - - if (print->autorotate) { -- double left_right_sides, top_bottom_sides; -- -- cairo_translate (cr, (cr_width - scale * width) / 2, -- (cr_height - scale * height) / 2); -+ x_offset = (cr_width - scale * width) / 2; -+ y_offset = (cr_height - scale * height) / 2; -+ cairo_device_to_user (cr, &x_offset, &y_offset); -+ cairo_translate (cr, x_offset, y_offset); - - /* Ensure document page is within the margins. The - * scale guarantees the document will fit in the - * margins so we just need to check each side and - * if it overhangs the margin, translate it to the -- * margin. */ -- left_right_sides = (cr_width - width*scale)/2; -- top_bottom_sides = (cr_height - height*scale)/2; -- if (left_right_sides < left) -- cairo_translate (cr, left - left_right_sides, 0); -+ * margin. */ -+ if (x_offset < left) -+ cairo_translate (cr, left - x_offset, 0); - -- if (left_right_sides < right) -- cairo_translate (cr, -(right - left_right_sides), 0); -+ if (x_offset < right) -+ cairo_translate (cr, -(right - x_offset), 0); - -- if (top_bottom_sides < top) -- cairo_translate (cr, 0, top - top_bottom_sides); -+ if (y_offset < top) -+ cairo_translate (cr, 0, top - y_offset); - -- if (top_bottom_sides < bottom) -- cairo_translate (cr, 0, -(bottom - top_bottom_sides)); -+ if (y_offset < bottom) -+ cairo_translate (cr, 0, -(bottom - y_offset)); - } else { - cairo_translate (cr, left, top); - } --- -2.1.0 - diff --git a/0001-recent-view-Check-whether-load-job-succeeded.patch b/0001-recent-view-Check-whether-load-job-succeeded.patch deleted file mode 100644 index add7f9e..0000000 --- a/0001-recent-view-Check-whether-load-job-succeeded.patch +++ /dev/null @@ -1,32 +0,0 @@ -From afc1a86c2d706ae2ea4866581ba2522288a4437f Mon Sep 17 00:00:00 2001 -From: Marek Kasik -Date: Wed, 11 Feb 2015 11:52:09 +0100 -Subject: [PATCH 1/9] recent-view: Check whether load job succeeded - -Check whether document load job succeeded before proceeding its metadata. -This fixes crash when there are no recent files and you are trying to open -password protected PDF file -(see https://bugzilla.redhat.com/show_bug.cgi?id=1189222). - -https://bugzilla.gnome.org/show_bug.cgi?id=744049 ---- - shell/ev-recent-view.c | 3 ++- - 1 file changed, 2 insertions(+), 1 deletion(-) - -diff --git a/shell/ev-recent-view.c b/shell/ev-recent-view.c -index fb0004c..facea47 100644 ---- a/shell/ev-recent-view.c -+++ b/shell/ev-recent-view.c -@@ -366,7 +366,8 @@ document_load_job_completed_callback (EvJobLoad *job_load, - EvRecentViewPrivate *priv = data->ev_recent_view->priv; - EvDocument *document = EV_JOB (job_load)->document; - -- if (g_cancellable_is_cancelled (data->cancellable) || !document) { -+ if (g_cancellable_is_cancelled (data->cancellable) || -+ ev_job_is_failed (EV_JOB (job_load))) { - get_document_info_async_data_free (data); - return; - } --- -2.1.0 - diff --git a/0002-Show-correct-page-when-next-search-result-requested.patch b/0002-Show-correct-page-when-next-search-result-requested.patch deleted file mode 100644 index 91a5836..0000000 --- a/0002-Show-correct-page-when-next-search-result-requested.patch +++ /dev/null @@ -1,41 +0,0 @@ -From d39c99cbb1c28a894b09f467b18e34754fd6842f Mon Sep 17 00:00:00 2001 -From: Marek Kasik -Date: Tue, 18 Nov 2014 12:53:40 +0100 -Subject: [PATCH 2/2] Show correct page when next search result requested - -If there are more than 1 results on a page then requesting -next search result from the same page will not return you -to the page with the search results if you moved from the -page in the meantime (when you are not in continuous mode). -This applies also to previous results. - -https://bugzilla.gnome.org/show_bug.cgi?id=730252 ---- - libview/ev-view.c | 4 ++++ - 1 file changed, 4 insertions(+) - -diff --git a/libview/ev-view.c b/libview/ev-view.c -index f3aa033..a9159cd 100644 ---- a/libview/ev-view.c -+++ b/libview/ev-view.c -@@ -8250,6 +8250,8 @@ ev_view_find_next (EvView *view) - if (view->find_result >= n_results) { - view->find_result = 0; - jump_to_find_page (view, EV_VIEW_FIND_NEXT, 1); -+ } else if (view->find_page != view->current_page) { -+ jump_to_find_page (view, EV_VIEW_FIND_NEXT, 0); - } - - jump_to_find_result (view); -@@ -8264,6 +8266,8 @@ ev_view_find_previous (EvView *view) - if (view->find_result < 0) { - jump_to_find_page (view, EV_VIEW_FIND_PREV, -1); - view->find_result = MAX (0, ev_view_find_get_n_results (view, view->find_page) - 1); -+ } else if (view->find_page != view->current_page) { -+ jump_to_find_page (view, EV_VIEW_FIND_PREV, 0); - } - - jump_to_find_result (view); --- -2.1.0 - diff --git a/evince.spec b/evince.spec index 2f15e83..7cd5d12 100644 --- a/evince.spec +++ b/evince.spec @@ -4,8 +4,8 @@ %global gxps_version 0.2.1 Name: evince -Version: 3.14.1 -Release: 9%{?dist} +Version: 3.14.2 +Release: 1%{?dist} Summary: Document viewer License: GPLv2+ and GPLv3+ and LGPLv2+ and MIT and Afmparse @@ -13,24 +13,6 @@ Group: Applications/Publishing URL: http://projects.gnome.org/evince/ Source0: http://download.gnome.org/sources/%{name}/3.14/%{name}-%{version}.tar.xz -# https://bugzilla.redhat.com/show_bug.cgi?id=1160376 -Patch0: 0001-Disable-toggle-find-action-for-documents-not-support.patch - -Patch1: 0001-Fix-runtime-critical-warning-when-starting-in-fullsc.patch - -# https://bugzilla.redhat.com/show_bug.cgi?id=1162254 -Patch2: 0001-Scroll-to-the-search-result-selected-by-user.patch -Patch3: 0002-Show-correct-page-when-next-search-result-requested.patch - -# https://bugzilla.redhat.com/show_bug.cgi?id=1147270 -Patch4: 0001-Fix-configuration-with-ligbnome-desktop.patch - -# https://bugzilla.redhat.com/show_bug.cgi?id=1173832 -Patch5: 0001-print-operation-Fix-centering-of-documents-when-prin.patch - -# https://bugzilla.redhat.com/show_bug.cgi?id=1189222 -Patch6: 0001-recent-view-Check-whether-load-job-succeeded.patch - BuildRequires: glib2-devel >= %{glib2_version} BuildRequires: gtk3-devel >= %{gtk3_version} BuildRequires: poppler-glib-devel >= %{poppler_version} @@ -140,14 +122,6 @@ This package contains the evince web browser plugin. %prep %setup -q -%patch0 -p1 -b .toggle-find -%patch1 -p1 -b .unref -%patch2 -p1 -b .scroll-to-search-result -%patch3 -p1 -b .scroll-to-search-result2 -%patch4 -p1 -b .libgnome-desktop -%patch5 -p1 -R -b .centering-of-printing -%patch6 -p1 -b .load-job - %build ./autogen.sh %configure \ @@ -280,6 +254,9 @@ glib-compile-schemas %{_datadir}/glib-2.0/schemas >&/dev/null ||: %{_libdir}/mozilla/plugins/libevbrowserplugin.so %changelog +* Mon Mar 9 2015 Marek Kasik - 3.14.2-1 +- Update to 3.14.2 + * Mon Feb 16 2015 Marek Kasik - 3.14.1-9 - Check whether document load job succeeded before proceeding its metadata. - Resolves: #1189222 diff --git a/sources b/sources index 98f276a..ea6b104 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -20575f13ce1a0bf31f085d2430848c40 evince-3.14.1.tar.xz +7f7ad8f3ddef0b09d8b588e911152ecc evince-3.14.2.tar.xz