Skip to content
Commit e7eafa19 authored by Peter Hutterer's avatar Peter Hutterer
Browse files

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: default avatarPeter Hutterer <peter.hutterer@who-t.net>
parent d13ab268
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment