diff options
author | Ander Conselvan de Oliveira <ander@mandriva.com.br> | 2008-06-26 14:36:58 -0300 |
---|---|---|
committer | Peter Hutterer <peter.hutterer@who-t.net> | 2008-07-10 19:29:45 +0930 |
commit | 52fc8ee84656728a82073eae16da9e878cc3b39f (patch) | |
tree | 749623818c4d5cf5e0e1440a25b99471bf3e936a | |
parent | evdev 2.0.1 (diff) | |
download | xf86-input-evdev-52fc8ee84656728a82073eae16da9e878cc3b39f.tar.gz xf86-input-evdev-52fc8ee84656728a82073eae16da9e878cc3b39f.tar.bz2 xf86-input-evdev-52fc8ee84656728a82073eae16da9e878cc3b39f.zip |
Mice with a lot of buttons (e.g. Logitech MX1000) generate button events greater than BTN_TASK.
Signed-off-by: Peter Hutterer <peter@cs.unisa.edu.au>
(cherry picked from commit 0830676a0ce3618eae9cf4c072998c16e164c687)
-rw-r--r-- | src/evdev.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/evdev.c b/src/evdev.c index 0078881..da6fa3b 100644 --- a/src/evdev.c +++ b/src/evdev.c @@ -252,8 +252,15 @@ EvdevReadInput(InputInfoPtr pInfo) break; default: - if (ev.code > BTN_TASK && ev.code < KEY_OK) + if (ev.code > BTN_TASK && ev.code < KEY_OK) { + /* Some fancy mice with a lot of buttons generate + * button events between BTN_TASK and BTN_JOYSTICK */ + if (ev.code < BTN_JOYSTICK) + xf86PostButtonEvent(pInfo->dev, 0, + ev.code - BTN_LEFT + 5, + value, 0, 0); break; + } PostKbdEvent(pInfo, &ev, value); break; |