From 372018254ef9d5ad2672e0359e8ba23b3e4c0f3d Mon Sep 17 00:00:00 2001 From: Carlos Garcia Campos Date: Fri, 12 Jul 2013 14:38:38 +0200 Subject: libview: Stop the cursor blink when there are selections active Even though the caret cursor is not shown while there are active selections we don't want the cursor blink timeout running and scheduling redraws. origin commit: https://git.gnome.org/browse/evince/commit/?h=gnome-3-10&id=41c660f --- libview/ev-view.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'libview') diff --git a/libview/ev-view.c b/libview/ev-view.c index b9e79026..06bc8c8f 100644 --- a/libview/ev-view.c +++ b/libview/ev-view.c @@ -3245,7 +3245,9 @@ cursor_should_blink (EvView *view) { if (view->caret_enabled && view->rotation == 0 && - gtk_widget_has_focus (GTK_WIDGET (view))) { + gtk_widget_has_focus (GTK_WIDGET (view)) && + view->pixbuf_cache && + !ev_pixbuf_cache_get_selection_region (view->pixbuf_cache, view->cursor_page, view->scale)) { GtkSettings *settings; gboolean blink; @@ -7767,6 +7769,8 @@ merge_selection_region (EvView *view, } } + ev_view_check_cursor_blink (view); + /* Free the old list, now that we're done with it. */ g_list_free_full (old_list, (GDestroyNotify)selection_free); } -- cgit v1.2.1