mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-12-26 13:41:07 +00:00
scrolledwindow: fix scrolling with shared adjustment
The GtkPolicyType set on the scrollbar is just about the presentation. What matters for scrolling is the adjustment. https://bugzilla.gnome.org/show_bug.cgi?id=730730
This commit is contained in:
parent
c389fc64f7
commit
f0478c3dfd
@ -2349,8 +2349,7 @@ gtk_scrolled_window_scroll_event (GtkWidget *widget,
|
||||
|
||||
if (gdk_event_get_scroll_deltas ((GdkEvent *) event, &delta_x, &delta_y))
|
||||
{
|
||||
if (delta_x != 0.0 &&
|
||||
gtk_widget_get_visible (priv->hscrollbar))
|
||||
if (delta_x != 0.0)
|
||||
{
|
||||
GtkAdjustment *adj;
|
||||
gdouble new_value;
|
||||
@ -2371,8 +2370,7 @@ gtk_scrolled_window_scroll_event (GtkWidget *widget,
|
||||
handled = TRUE;
|
||||
}
|
||||
|
||||
if (delta_y != 0.0 &&
|
||||
gtk_widget_get_visible (priv->vscrollbar))
|
||||
if (delta_y != 0.0)
|
||||
{
|
||||
GtkAdjustment *adj;
|
||||
gdouble new_value;
|
||||
@ -2402,7 +2400,7 @@ gtk_scrolled_window_scroll_event (GtkWidget *widget,
|
||||
else
|
||||
range = priv->hscrollbar;
|
||||
|
||||
if (range && gtk_widget_get_visible (range))
|
||||
if (range)
|
||||
{
|
||||
GtkAdjustment *adj = gtk_range_get_adjustment (GTK_RANGE (range));
|
||||
gdouble new_value;
|
||||
|
Loading…
Reference in New Issue
Block a user