Bug 45611

Summary: erratic scrolling in 1.12
Product: xorg Reporter: Timo Aaltonen <tjaalton>
Component: Server/Input/CoreAssignee: Peter Hutterer <peter.hutterer>
Status: RESOLVED FIXED QA Contact: Xorg Project Team <xorg-team>
Severity: normal    
Priority: medium CC: ahmadsamir3891, chase.douglas, peter.hutterer, rjones
Version: unspecified   
Hardware: Other   
OS: All   
Whiteboard:
i915 platform: i915 features:
Bug Depends on:    
Bug Blocks: 40982    
Attachments:
Description Flags
0001-dix-reset-last.scroll-when-resetting-the-valuator-45.patch none

Description Timo Aaltonen 2012-02-04 02:42:46 UTC
forwarded from https://bugs.launchpad.net/ubuntu/+source/xorg-server/+bug/925785

TL;DR, plug another pointer device with horiz scroll support, then after touching the other device try to scroll with the second device and notice how "many" scroll button events are emitted.
Comment 1 Timo Aaltonen 2012-02-04 02:54:41 UTC
Actually, the scroll axis doesn't matter, it's the same for both horizontal and vertical (meant vertical originally). Just that for vertical scrolls the jumping happens to the other direction (since the axis seems reversed, I'll file another bug about that..).
Comment 2 Timo Aaltonen 2012-02-04 03:05:40 UTC
another observation:

- touch device 1
- scroll device 2, note that it jumps
- touch device 1
- scroll device 2 to the same direction as before, note that nothing happens on the first click, the next one is normal
- touch device 2
- scroll device 2 to the same direction as before, note that you get _opposite_ action on the first click, next one is normal

... :)
Comment 3 Peter Hutterer 2012-02-04 09:57:33 UTC
verified on master, thanks.

Appears to be a bad update of last.valuators[], resetting that value to 0 whenever the SD changes. As a result, the next value isn't on top of the previous one but rather starting from 0, causing a bad in value. The jumps come from that
Comment 4 Peter Hutterer 2012-02-10 07:31:33 UTC
Created attachment 56877 [details] [review]
0001-dix-reset-last.scroll-when-resetting-the-valuator-45.patch

How does this one work for you?
Comment 5 Timo Aaltonen 2012-02-10 07:47:52 UTC
Nice! Works great.

Tested-by: Timo Aaltonen <timo.aaltonen@canonical.com>
Comment 6 Peter Hutterer 2012-02-21 21:13:18 UTC
commit 6f28388187cffae9e5bc9bfc9425acff4f478b59
Author: Peter Hutterer <peter.hutterer@who-t.net>
Date:   Sat Feb 11 01:29:26 2012 +1000

    dix: reset last.scroll when resetting the valuator (#45611)
Comment 7 Richard W.M. Jones 2015-07-20 21:09:51 UTC
This bug -- or something remarkably similar to it -- has reappeared in 1.17.2 (latest X package in Fedora 22).
Comment 8 Peter Hutterer 2015-08-04 06:58:21 UTC
This ended up being a GTK3 bug, not an xorg bug, see https://bugzilla.redhat.com/show_bug.cgi?id=1245247. Closing again

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.