X-Git-Url: https://www.fi.muni.cz/~kas/git//home/kas/public_html/git/?a=blobdiff_plain;f=shell%2Fev-window.c;h=89d18d997863c792ca245cf7ebd2140f681f0b63;hb=8c953cdc1375d46bd4fcc9341ec263b6b2eedad8;hp=fac2a119748f8ff37bdb3c298e410863d32f31bd;hpb=1ecd95c77d53b2921e555549b4fd53308a49572b;p=evince.git diff --git a/shell/ev-window.c b/shell/ev-window.c index fac2a119..89d18d99 100644 --- a/shell/ev-window.c +++ b/shell/ev-window.c @@ -56,7 +56,6 @@ #include "ev-document-fonts.h" #include "ev-document-images.h" #include "ev-document-links.h" -#include "ev-document-thumbnails.h" #include "ev-document-annotations.h" #include "ev-document-type-builtins.h" #include "ev-document-misc.h" @@ -1310,8 +1309,7 @@ ev_window_refresh_window_thumbnail (EvWindow *ev_window) gint rotation; EvDocument *document = ev_window->priv->document; - if (!EV_IS_DOCUMENT_THUMBNAILS (document) || - ev_document_get_n_pages (document) <= 0 || + if (ev_document_get_n_pages (document) <= 0 || !ev_document_check_dimensions (document)) { return; } @@ -4858,17 +4856,23 @@ ev_window_update_find_status_message (EvWindow *ev_window) return; if (ev_job_is_finished (ev_window->priv->find_job)) { - gint n_results; - - n_results = ev_job_find_get_n_results (EV_JOB_FIND (ev_window->priv->find_job), - ev_document_model_get_page (ev_window->priv->model)); - /* TRANS: Sometimes this could be better translated as - "%d hit(s) on this page". Therefore this string - contains plural cases. */ - message = g_strdup_printf (ngettext ("%d found on this page", - "%d found on this page", - n_results), - n_results); + EvJobFind *job_find = EV_JOB_FIND (ev_window->priv->find_job); + + if (ev_job_find_has_results (job_find)) { + gint n_results; + + n_results = ev_job_find_get_n_results (job_find, + ev_document_model_get_page (ev_window->priv->model)); + /* TRANS: Sometimes this could be better translated as + "%d hit(s) on this page". Therefore this string + contains plural cases. */ + message = g_strdup_printf (ngettext ("%d found on this page", + "%d found on this page", + n_results), + n_results); + } else { + message = g_strdup (_("Not found")); + } } else { gdouble percent;