summaryrefslogtreecommitdiff
path: root/shell
diff options
context:
space:
mode:
authorraveit65 <[email protected]>2016-06-24 18:32:07 +0200
committermonsta <[email protected]>2016-08-09 21:58:29 +0300
commitc791ee64b8c0bf0c58f026a90df549bf00ecef2c (patch)
treef6409db79fa90bd23fd2f12c8538226ed207954c /shell
parentc40e801641802df4a0a07a32cae68cf48a4daf60 (diff)
downloadatril-c791ee64b8c0bf0c58f026a90df549bf00ecef2c.tar.bz2
atril-c791ee64b8c0bf0c58f026a90df549bf00ecef2c.tar.xz
Refresh thumbnail only when window has a document
This prevents a critical warning when opening a document that was rotated in a previous Evince session. taken from: https://git.gnome.org/browse/evince/commit/?id=1b5cf70
Diffstat (limited to 'shell')
-rw-r--r--shell/ev-window.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/shell/ev-window.c b/shell/ev-window.c
index e30d36d2..67fe7e77 100644
--- a/shell/ev-window.c
+++ b/shell/ev-window.c
@@ -1452,7 +1452,7 @@ ev_window_refresh_window_thumbnail (EvWindow *ev_window)
gint rotation;
EvDocument *document = ev_window->priv->document;
- if (!EV_IS_DOCUMENT_THUMBNAILS (document) ||
+ if (!document || ev_document_get_n_pages (document) <= 0 ||
ev_document_get_n_pages (document) <= 0 ||
!ev_document_check_dimensions (document)) {
return;