[gnome-documents] preview: Fix possible warnings exiting fullscreen
- From: Bastien Nocera <hadess src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-documents] preview: Fix possible warnings exiting fullscreen
- Date: Fri, 11 Dec 2015 10:54:01 +0000 (UTC)
commit cd6d7c76ddf063fe0f285044c06ced0ce45e97d7
Author: Bastien Nocera <hadess hadess net>
Date: Wed Dec 9 14:35:10 2015 +0100
preview: Fix possible warnings exiting fullscreen
After opening a document, turning on the fullscreen mode, and starting a
search (type a few letters), you'll get warnings from EvView when "Esc"
is pressed.
This is caused by the search being reset when exiting the preview. As we
don't have a document, or document model anymore, there's no search to
be done.
https://bugzilla.gnome.org/show_bug.cgi?id=759248
src/preview.js | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/src/preview.js b/src/preview.js
index 6ce6ce6..ddac1e3 100644
--- a/src/preview.js
+++ b/src/preview.js
@@ -568,6 +568,10 @@ const PreviewView = new Lang.Class({
this._updateNightMode();
this.set_visible_child_full('view', Gtk.StackTransitionType.NONE);
+ } else {
+ if (!this._jobFind.is_finished())
+ this._jobFind.cancel();
+ this._jobFind = null;
}
},
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]