forked from AuroraMiddleware/gtk
Do not filter out small scroll event fractions
The scroll motion values are subject of batching and scaling. Either through scaling or by using a touchpad smooth scroll motion changes below 0.5 are possible. https://bugzilla.gnome.org/show_bug.cgi?id=769554 Signed-off-by: Andreas Pokorny <andreas.pokorny@canonical.com>
This commit is contained in:
parent
ea0436c3b5
commit
fe216b0039
@ -196,7 +196,7 @@ generate_scroll_event (GdkWindow *window, gdouble x, gdouble y, gdouble delta_x,
|
||||
else
|
||||
{
|
||||
event->scroll.direction = GDK_SCROLL_SMOOTH;
|
||||
event->scroll.delta_x = -delta_x;
|
||||
event->scroll.delta_x = delta_x;
|
||||
event->scroll.delta_y = -delta_y;
|
||||
}
|
||||
|
||||
@ -403,7 +403,7 @@ handle_motion_event (GdkWindow *window, const MirInputEvent *event)
|
||||
hscroll = mir_pointer_event_axis_value (pointer_event, mir_pointer_axis_hscroll);
|
||||
vscroll = mir_pointer_event_axis_value (pointer_event, mir_pointer_axis_vscroll);
|
||||
|
||||
if (ABS (hscroll) > 0.5 || ABS (vscroll) > 0.5)
|
||||
if (hscroll != 0.0 || vscroll != 0.0)
|
||||
generate_scroll_event (window, x, y, hscroll, vscroll, modifier_state, event_time);
|
||||
if (ABS (new_x - x) > 0.5 || ABS (new_y - y) > 0.5)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user