File xf86-input-dmc.diff of Package xorg-x11-driver-input

commit 3c75c2bed83d9a762dc268dfa797826a3b198932
Author: Peter Hutterer <peter@cs.unisa.edu.au>
Date:   Mon May 26 22:05:06 2008 +0930

    Check for XINPUT ABI 3.

diff --git a/src/xf86DMC.c b/src/xf86DMC.c
index e6797d8..daa0f20 100644
--- a/src/xf86DMC.c
+++ b/src/xf86DMC.c
@@ -106,7 +106,9 @@ static const char *reqSymbols[] = {
 	"xf86CollectInputOptions",
 	"xf86ErrorFVerb",
 	"xf86FindOptionValue",
+#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) < 3
 	"xf86GetMotionEvents",
+#endif
 	"xf86GetVerbosity",
 	"xf86MotionHistoryAllocate",
 	"xf86NameCmp",
@@ -301,7 +303,10 @@ DeviceControl (DeviceIntPtr dev, int mode)
 		 * Device reports motions on 2 axes in absolute coordinates.
 		 * Axes min and max values are reported in raw coordinates.
 		 */
-		if (InitValuatorClassDeviceStruct (dev, 2, xf86GetMotionEvents,
+		if (InitValuatorClassDeviceStruct (dev, 2,
+#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) < 3
+                            xf86GetMotionEvents,
+#endif
 						   pInfo->history_size, Absolute) == FALSE)
 			{
 				ErrorF ("Unable to allocate DMC ValuatorClassDeviceStruct\n");
openSUSE Build Service is sponsored by