diff options
author | rootavish <[email protected]> | 2014-08-06 17:22:34 +0530 |
---|---|---|
committer | rootavish <[email protected]> | 2014-08-06 17:22:34 +0530 |
commit | 683022d92b63bea1544e8d19bc57d47ef84f5fff (patch) | |
tree | 3b88ec7ac949efb3faa2fd8c065dc7f6854b12b9 /shell | |
parent | 56880392a6678ccec12bbec016939597acd49b07 (diff) | |
download | atril-683022d92b63bea1544e8d19bc57d47ef84f5fff.tar.bz2 atril-683022d92b63bea1544e8d19bc57d47ef84f5fff.tar.xz |
Redesigned the thumbnail code for ePub
No more crashes when searching with the sidebar open, will probably add a pixbuf cache as well to speed it up even further.
The process which I earlier thought was not possible without separate jobs, work just fine as a single job, if I change the run mode of the thumbnail job, and incorporate a trylock() in case of epub.
Diffstat (limited to 'shell')
-rw-r--r-- | shell/ev-sidebar-thumbnails.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/shell/ev-sidebar-thumbnails.c b/shell/ev-sidebar-thumbnails.c index 5c4cb4be..a6102355 100644 --- a/shell/ev-sidebar-thumbnails.c +++ b/shell/ev-sidebar-thumbnails.c @@ -442,7 +442,6 @@ add_range (EvSidebarThumbnails *sidebar_thumbnails, result && page <= end_page; result = gtk_tree_model_iter_next (GTK_TREE_MODEL (priv->list_store), &iter), page ++) { EvJob *job; - gboolean thumbnail_set; gtk_tree_model_get (GTK_TREE_MODEL (priv->list_store), &iter, @@ -455,6 +454,10 @@ add_range (EvSidebarThumbnails *sidebar_thumbnails, page, priv->rotation, get_scale_for_page (sidebar_thumbnails, page)); + if (priv->document->iswebdocument) { + ev_job_set_run_mode(job, EV_JOB_RUN_MAIN_LOOP); + } + ev_job_scheduler_push_job (EV_JOB (job), EV_JOB_PRIORITY_HIGH); g_object_set_data_full (G_OBJECT (job), "tree_iter", |