diff options
author | Carlos Garcia Campos <carlosgc@gnome.org> | 2007-05-19 12:33:33 (GMT) |
---|---|---|
committer | Carlos Garcia Campos <carlosgc@src.gnome.org> | 2007-05-19 12:33:33 (GMT) |
commit | 755adf12cff12b24acda4dc852df43e04ab7dfb7 (patch) | |
tree | 8feb144334f8cb2e684163e8ea56be745cf78594 | |
parent | 3487cb3d1064cc84efe4a95ea9346cc0f6d89485 (diff) |
Update cursor and tooltip on page change and view scroll. Fixes bug
2007-05-19 Carlos Garcia Campos <carlosgc@gnome.org>
* shell/ev-view.c: (page_changed_cb), (on_adjustment_value_changed):
Update cursor and tooltip on page change and view scroll. Fixes bug
#439217.
svn path=/trunk/; revision=2466
-rw-r--r-- | ChangeLog | 7 | ||||
-rw-r--r-- | shell/ev-view.c | 19 |
2 files changed, 21 insertions, 5 deletions
@@ -1,3 +1,10 @@ +2007-05-19 Carlos Garcia Campos <carlosgc@gnome.org> + + * shell/ev-view.c: (page_changed_cb), (on_adjustment_value_changed): + + Update cursor and tooltip on page change and view scroll. Fixes bug + #439217. + 2007-05-14 Nickolay V. Shmyrev <nshmyrev@yandex.ru> * NEWS: diff --git a/shell/ev-view.c b/shell/ev-view.c index d496a68..9f59ea1 100644 --- a/shell/ev-view.c +++ b/shell/ev-view.c @@ -1517,7 +1517,6 @@ handle_link_over_xy (EvView *view, gint x, gint y) view->cursor == EV_VIEW_CURSOR_IBEAM) ev_view_set_cursor (view, EV_VIEW_CURSOR_NORMAL); } - return; } /*** Images ***/ @@ -3406,10 +3405,17 @@ page_changed_cb (EvPageCache *page_cache, EvView *view) { if (view->current_page != new_page) { + gint x, y; + view->current_page = new_page; view->pending_scroll = SCROLL_TO_PAGE_POSITION; + if (view->presentation) ev_view_presentation_transition_start (view); + + gtk_widget_get_pointer (GTK_WIDGET (view), &x, &y); + handle_link_over_xy (view, x, y); + gtk_widget_queue_resize (GTK_WIDGET (view)); } else { gtk_widget_queue_draw (GTK_WIDGET (view)); @@ -3421,10 +3427,12 @@ page_changed_cb (EvPageCache *page_cache, } } -static void on_adjustment_value_changed (GtkAdjustment *adjustment, - EvView *view) +static void +on_adjustment_value_changed (GtkAdjustment *adjustment, + EvView *view) { int dx = 0, dy = 0; + gint x, y; if (! GTK_WIDGET_REALIZED (view)) return; @@ -3443,12 +3451,13 @@ static void on_adjustment_value_changed (GtkAdjustment *adjustment, view->scroll_y = 0; } - if (view->pending_resize) gtk_widget_queue_draw (GTK_WIDGET (view)); else gdk_window_scroll (GTK_WIDGET (view)->window, dx, dy); - + + gtk_widget_get_pointer (GTK_WIDGET (view), &x, &y); + handle_link_over_xy (view, x, y); if (view->document) view_update_range_and_current_page (view); |