summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Jaeger <thjaeger@gmail.com>2009-09-23 00:16:21 (GMT)
committerPeter Hutterer <peter.hutterer@who-t.net>2009-09-24 04:52:15 (GMT)
commit5402f18d9c3f7ba19cc05b3a814e3a9e94c8d551 (patch)
treee840d288717360ab1c66b5e3efe222fa0acc8c6f
parent33bf9cb69dccbb6889b2f83e6db61f40dc644e17 (diff)
dix: report XI1 axis values correctly if first_valuator != 0
Signed-off-by: Thomas Jaeger <ThJaeger@gmail.com> Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
-rw-r--r--dix/eventconvert.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/dix/eventconvert.c b/dix/eventconvert.c
index d91ba67..e25f3ee 100644
--- a/dix/eventconvert.c
+++ b/dix/eventconvert.c
@@ -352,17 +352,17 @@ getValuatorEvents(DeviceEvent *ev, deviceValuator *xv)
xv->device_state = state;
switch (xv->num_valuators) {
case 6:
- xv->valuator5 = ev->valuators.data[i + 5];
+ xv->valuator5 = ev->valuators.data[xv->first_valuator + 5];
case 5:
- xv->valuator4 = ev->valuators.data[i + 4];
+ xv->valuator4 = ev->valuators.data[xv->first_valuator + 4];
case 4:
- xv->valuator3 = ev->valuators.data[i + 3];
+ xv->valuator3 = ev->valuators.data[xv->first_valuator + 3];
case 3:
- xv->valuator2 = ev->valuators.data[i + 2];
+ xv->valuator2 = ev->valuators.data[xv->first_valuator + 2];
case 2:
- xv->valuator1 = ev->valuators.data[i + 1];
+ xv->valuator1 = ev->valuators.data[xv->first_valuator + 1];
case 1:
- xv->valuator0 = ev->valuators.data[i + 0];
+ xv->valuator0 = ev->valuators.data[xv->first_valuator + 0];
}
if (i + 6 < num_valuators)