diff --git a/atril.spec b/atril.spec index 287ab78..69d9f21 100644 --- a/atril.spec +++ b/atril.spec @@ -15,7 +15,7 @@ Name: atril Version: %{branch}.2 %if 0%{?rel_build} -Release: 1%{?dist} +Release: 2%{?dist} %else Release: 0.11%{?git_rel}%{?dist} %endif @@ -29,6 +29,9 @@ URL: http://mate-desktop.org # Source for snapshot-builds. %{!?rel_build:Source0: http://git.mate-desktop.org/%{name}/snapshot/%{name}-%{commit}.tar.xz#/%{git_tar}} +# https://github.com/mate-desktop/atril/commit/ecd0d8c +Patch1: atril_0001-libview-Reset-pressed_button-when-starting-Drag-and-.patch + BuildRequires: gcc-c++ BuildRequires: gtk3-devel BuildRequires: poppler-glib-devel @@ -201,6 +204,10 @@ desktop-file-validate ${RPM_BUILD_ROOT}%{_datadir}/applications/atril.desktop %changelog +* Sat Nov 23 2019 Wolfgang Ulbrich - 1.22.2-2 +- use https://github.com/mate-desktop/atril/commit/ecd0d8c +- Reset text selection after Drag and Drop + * Wed Sep 18 2019 Wolfgang Ulbrich - 1.22.2-1 - update to 1.22.2 diff --git a/atril_0001-libview-Reset-pressed_button-when-starting-Drag-and-.patch b/atril_0001-libview-Reset-pressed_button-when-starting-Drag-and-.patch new file mode 100644 index 0000000..67f8779 --- /dev/null +++ b/atril_0001-libview-Reset-pressed_button-when-starting-Drag-and-.patch @@ -0,0 +1,35 @@ +From 67a1ad97c385531746f754da7c12d1354840248d Mon Sep 17 00:00:00 2001 +From: Martin Wimpress +Date: Mon, 4 Nov 2019 18:57:50 +0000 +Subject: [PATCH] libview: Reset `pressed_button` when starting Drag and Drop + +If view->pressed_button is left set, when the Drag and Drop operation completes, Atril will act as if it is still in a selection event. + +Adapted from: https://gitlab.gnome.org/GNOME/evince/commit/92828bb797742e04aadbfdd62ba1da36837c37cf +--- + libview/ev-view.c | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/libview/ev-view.c b/libview/ev-view.c +index 02860a88..91d14cbf 100644 +--- a/libview/ev-view.c ++++ b/libview/ev-view.c +@@ -4808,6 +4808,7 @@ ev_view_motion_notify_event (GtkWidget *widget, + event->y); + + view->selection_info.in_drag = FALSE; ++ view->pressed_button = -1; + + gtk_target_list_unref (target_list); + +@@ -4830,6 +4831,7 @@ ev_view_motion_notify_event (GtkWidget *widget, + event->y); + + view->image_dnd_info.in_drag = FALSE; ++ view->pressed_button = -1; + + gtk_target_list_unref (target_list); + +-- +2.21.0 +