summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhilip Langdale <philipl@fido2.homeip.net>2007-09-10 20:46:13 -0700
committerPhilip Langdale <philipl@fido2.homeip.net>2007-09-10 20:46:13 -0700
commitb20b4c2388a19885b8d686bbc184d69bed5585d9 (patch)
tree09b1295a368309070e79fe770fcd36f688e0a605
parent0cd80f9869feef92261d0972f3d2d018a3dcfb18 (diff)
parentd8e1d4d1f4eeeb87c573810c0f0d141fe180bb01 (diff)
Merge branch 'master' of git+ssh://git.freedesktop.org/git/xorg/driver/xf86-input-vmmouse
-rw-r--r--src/vmmouse.c18
1 files changed, 16 insertions, 2 deletions
diff --git a/src/vmmouse.c b/src/vmmouse.c
index af24848..10859b4 100644
--- a/src/vmmouse.c
+++ b/src/vmmouse.c
@@ -344,7 +344,9 @@ VMMousePreInit(InputDriverPtr drv, IDevPtr dev, int flags)
pInfo->flags = XI86_POINTER_CAPABLE | XI86_SEND_DRAG_EVENTS;
pInfo->device_control = VMMouseDeviceControl;
pInfo->read_input = VMMouseReadInput;
+#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) == 0
pInfo->motion_history_proc = xf86GetMotionEvents;
+#endif
pInfo->control_proc = VMMouseControlProc;
pInfo->close_proc = VMMouseCloseProc;
pInfo->switch_mode = VMMouseSwitchMode;
@@ -774,8 +776,18 @@ VMMouseDeviceControl(DeviceIntPtr device, int mode)
InitPointerDeviceStruct((DevicePtr)device, map,
min(pMse->buttons, MSE_MAXBUTTONS),
- miPointerGetMotionEvents, pMse->Ctrl,
- miPointerGetMotionBufferSize());
+#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) == 0
+ miPointerGetMotionEvents,
+#else
+ GetMotionHistory,
+#endif
+ pMse->Ctrl,
+#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) == 0
+ miPointerGetMotionBufferSize()
+#else
+ GetMotionHistorySize(), 2
+#endif
+ );
/* X valuator */
xf86InitValuatorAxisStruct(device, 0, 0, -1, 1, 0, 1);
@@ -783,7 +795,9 @@ VMMouseDeviceControl(DeviceIntPtr device, int mode)
/* Y valuator */
xf86InitValuatorAxisStruct(device, 1, 0, -1, 1, 0, 1);
xf86InitValuatorDefaults(device, 1);
+#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) == 0
xf86MotionHistoryAllocate(pInfo);
+#endif
xf86Msg(X_INFO, "VMWARE(0): VMMOUSE DEVICE_INIT\n");
#ifdef EXTMOUSEDEBUG