From eb72fc5f1b6ca2b156516fda0f75c6e0ad367045 Mon Sep 17 00:00:00 2001 From: Carlos Garcia Campos Date: Mon, 25 Dec 2006 12:17:45 +0000 Subject: Update page-cache when page is changed by the view, so that page-changed 2006-12-25 Carlos Garcia Campos * shell/ev-view.c: (goto_dest): Update page-cache when page is changed by the view, so that page-changed signal is emitted. --- (limited to 'shell/ev-view.c') diff --git a/shell/ev-view.c b/shell/ev-view.c index 8d65fb4..ad7ef61 100644 --- a/shell/ev-view.c +++ b/shell/ev-view.c @@ -1254,13 +1254,15 @@ static void goto_dest (EvView *view, EvLinkDest *dest) { EvLinkDestType type; - int page, n_pages; + int page, n_pages, current_page; page = ev_link_dest_get_page (dest); n_pages = ev_page_cache_get_n_pages (view->page_cache); if (page < 0 || page >= n_pages) return; + + current_page = view->current_page; type = ev_link_dest_get_dest_type (dest); @@ -1289,6 +1291,10 @@ goto_dest (EvView *view, EvLinkDest *dest) default: g_assert_not_reached (); } + + if (current_page != view->current_page) + ev_page_cache_set_current_page (view->page_cache, + view->current_page); } void -- cgit v0.9.1