- EvView *view = EV_VIEW (layout);
-
- set_scroll_adjustment (view, GTK_ORIENTATION_HORIZONTAL, hadjustment);
- set_scroll_adjustment (view, GTK_ORIENTATION_VERTICAL, vadjustment);
-
- on_adjustment_value_changed (NULL, view);
+ set_scroll_adjustment (view, GTK_ORIENTATION_HORIZONTAL, gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (view)));
+ on_adjustment_value_changed (NULL, view);
+}
+
+
+static void
+on_vadjustment_notify (EvView *view,
+ GParamSpec *pspec,
+ gpointer user_data)
+{
+ set_scroll_adjustment (view, GTK_ORIENTATION_VERTICAL, gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (view)));
+ on_adjustment_value_changed (NULL, view);