diff options
author | Peter Hutterer <peter.hutterer@who-t.net> | 2009-06-18 16:15:16 +1000 |
---|---|---|
committer | Peter Hutterer <peter.hutterer@who-t.net> | 2009-06-18 16:19:08 +1000 |
commit | 6ab23e4519ed4ce07b745c573ddf544a2a1ee1b2 (patch) | |
tree | 56b8eb93955318279bd07c618a4e357d5123b418 /src | |
parent | 88eedea281a710008a82f1e6af4bdffd19477f46 (diff) |
Add missing checks for ABI_XINPUT_VERSION 7.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Diffstat (limited to 'src')
-rw-r--r-- | src/evdev.c | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/src/evdev.c b/src/evdev.c index 7dc8eb4..1d2ca36 100644 --- a/src/evdev.c +++ b/src/evdev.c @@ -1033,7 +1033,10 @@ EvdevAddAbsClass(DeviceIntPtr device) if (!TestBit(axis, pEvdev->abs_bitmask)) continue; pEvdev->axis_map[axis] = i; - xf86InitValuatorAxisStruct(device, i, atoms[axis], + xf86InitValuatorAxisStruct(device, i, +#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) >= 7 + atoms[axis], +#endif pEvdev->absinfo[axis].minimum, pEvdev->absinfo[axis].maximum, 10000, 0, 10000); @@ -1127,7 +1130,11 @@ EvdevAddRelClass(DeviceIntPtr device) if (axnum == -1) continue; - xf86InitValuatorAxisStruct(device, axnum, atoms[axnum], -1, -1, 1, 0, 1); + xf86InitValuatorAxisStruct(device, axnum, +#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) >= 7 + atoms[axnum], +#endif + -1, -1, 1, 0, 1); xf86InitValuatorDefaults(device, axnum); } @@ -1154,7 +1161,11 @@ EvdevAddButtonClass(DeviceIntPtr device) labels = xalloc(pEvdev->num_buttons * sizeof(Atom)); EvdevInitButtonLabels(pEvdev, pEvdev->num_buttons, labels); - if (!InitButtonClassDeviceStruct(device, pEvdev->num_buttons, labels, pEvdev->btnmap)) + if (!InitButtonClassDeviceStruct(device, pEvdev->num_buttons, +#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) >= 7 + labels, +#endif + pEvdev->btnmap)) return !Success; xfree(labels); |