Handle scroll wheel events with a discrete of 0
The driver currently assumes that any wheel event has a non-zero discrete
value of 1. This is incorrect, it just hasn't triggered yet with any device.
With the hi-res scroll patches in place in the kernel and libinput, we may get
wheel events with a discrete value of 0. We assume that if this ever happens,
the device has some sensible click angle set so all we need to do is ignore
the discrete 0 events and wait for the first discrete event to come.
Also add an explanatory comment too to make it clear the calculation is only
done once.
Fixes #19
Signed-off-by:
Peter Hutterer <peter.hutterer@who-t.net>
Loading
Please register or sign in to comment