After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 747133 - overshoot animation is stopped on libinput-managed touchpads
overshoot animation is stopped on libinput-managed touchpads
Status: RESOLVED FIXED
Product: gtk+
Classification: Platform
Component: Widget: GtkScrolledWindow
unspecified
Other Linux
: Normal normal
: ---
Assigned To: gtkdev
gtkdev
Depends on:
Blocks:
 
 
Reported: 2015-03-31 18:42 UTC by Carlos Garnacho
Modified: 2015-04-01 14:26 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
scrolledwindow: Ignore 0/0 scroll events when possibly cancelling animation (1.08 KB, patch)
2015-03-31 18:43 UTC, Carlos Garnacho
accepted-commit_now Details | Review

Description Carlos Garnacho 2015-03-31 18:42:26 UTC
If I scroll towards and edge with the touchpad, and move the pointer right away (got 2finger scrolling enabled, maybe makes this more easy/frequent), the overshoot gradient stays set mid-position until the next time scroll events are received.

I traced this to the 0/0 scroll event that the libinput driver sends on touchpads to indicate that scrolling finished, it happens to come after the first motion event, which confuses scrolledwindow state and cancels early the kinetic/overshoot animation.

I'm attaching a patch that's a bit of a kludge, as we do want to eventually trigger kinetic scrolling on libinput touchpads on 0/0 scroll events, but the patch will at least stop this behavior.
Comment 1 Carlos Garnacho 2015-03-31 18:43:10 UTC
Created attachment 300700 [details] [review]
scrolledwindow: Ignore 0/0 scroll events when possibly cancelling animation

These should be used eventually to start kinetic scrolling, so should definitely
be ignored on cancellation.
Comment 2 Matthias Clasen 2015-04-01 11:29:47 UTC
Review of attachment 300700 [details] [review]:

would perhaps be good to add a comment explaining why this check is necessary ?
"libinput is generating scroll events with dx=dy=0"
Comment 3 Carlos Garnacho 2015-04-01 14:26:02 UTC
Pushed with an added comment as suggested.

Attachment 300700 [details] pushed as b169643 - scrolledwindow: Ignore 0/0 scroll events when possibly cancelling animation