From a48b52684e184cac7979247c4a5af4250a9aa809 Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Fri, 10 Sep 2010 10:08:41 +1000 Subject: Replace LocalDevicePtr with InputInfoPtr. LocalDevicePtr was removed with input ABI 12, but InputInfoPtr has been around for years anyway. Signed-off-by: Peter Hutterer --- src/acecad.c | 26 +++++++++++++------------- src/acecad.h | 15 +++++++-------- 2 files changed, 20 insertions(+), 21 deletions(-) (limited to 'src') diff --git a/src/acecad.c b/src/acecad.c index 7bb80e4..2c2ff27 100644 --- a/src/acecad.c +++ b/src/acecad.c @@ -215,7 +215,7 @@ static char acecad_driver_name[11] = "usb_acecad"; #endif static Bool -AceCadAutoDevProbe(LocalDevicePtr local, int verb) +AceCadAutoDevProbe(InputInfoPtr local, int verb) { /* We are trying to find the right eventX device */ int i = 0; @@ -331,7 +331,7 @@ ProbeFound: static InputInfoPtr AceCadPreInit(InputDriverPtr drv, IDevPtr dev, int flags) { - LocalDevicePtr local = xf86AllocateInput(drv, 0); + InputInfoPtr local = xf86AllocateInput(drv, 0); AceCadPrivatePtr priv = xcalloc (1, sizeof(AceCadPrivateRec)); int speed; int msgtype; @@ -526,7 +526,7 @@ static Bool DeviceOn (DeviceIntPtr dev) { char buffer[256]; - LocalDevicePtr local = (LocalDevicePtr) dev->public.devicePrivate; + InputInfoPtr local = (InputInfoPtr) dev->public.devicePrivate; AceCadPrivatePtr priv = (AceCadPrivatePtr) (local->private); xf86MsgVerb(X_INFO, 4, "%s Device On\n", local->name); @@ -569,7 +569,7 @@ DeviceOn (DeviceIntPtr dev) static Bool DeviceOff (DeviceIntPtr dev) { - LocalDevicePtr local = (LocalDevicePtr) dev->public.devicePrivate; + InputInfoPtr local = (InputInfoPtr) dev->public.devicePrivate; AceCadPrivatePtr priv = (AceCadPrivatePtr) (local->private); xf86MsgVerb(X_INFO, 4, "%s Device Off\n", local->name); @@ -594,7 +594,7 @@ DeviceOff (DeviceIntPtr dev) static Bool DeviceClose (DeviceIntPtr dev) { - LocalDevicePtr local = (LocalDevicePtr) dev->public.devicePrivate; + InputInfoPtr local = (InputInfoPtr) dev->public.devicePrivate; xf86MsgVerb(X_INFO, 4, "%s Device Close\n", local->name); @@ -604,7 +604,7 @@ DeviceClose (DeviceIntPtr dev) static void ControlProc(DeviceIntPtr dev, PtrCtrl *ctrl) { - LocalDevicePtr local = (LocalDevicePtr) dev->public.devicePrivate; + InputInfoPtr local = (InputInfoPtr) dev->public.devicePrivate; xf86MsgVerb(X_INFO, 4, "%s Control Proc\n", local->name); } @@ -613,7 +613,7 @@ static Bool DeviceInit (DeviceIntPtr dev) { int rx, ry; - LocalDevicePtr local = (LocalDevicePtr) dev->public.devicePrivate; + InputInfoPtr local = (InputInfoPtr) dev->public.devicePrivate; AceCadPrivatePtr priv = (AceCadPrivatePtr) (local->private); unsigned char map[] = {0, 1, 2, 3}; #if GET_ABI_MAJOR(ABI_XINPUT_VERSION) >= 7 @@ -754,7 +754,7 @@ DeviceInit (DeviceIntPtr dev) } static void -ReadInput (LocalDevicePtr local) +ReadInput (InputInfoPtr local) { int x, y, z; int prox, buttons; @@ -856,7 +856,7 @@ ReadInput (LocalDevicePtr local) #ifdef HAVE_LINUX_INPUT_H #define set_bit(byte,nb,bit) (bit ? byte | (1<private; unsigned long bit[EV_MAX][NBITS(KEY_MAX)]; diff --git a/src/acecad.h b/src/acecad.h index fc06348..49721e0 100644 --- a/src/acecad.h +++ b/src/acecad.h @@ -100,21 +100,20 @@ static Bool DeviceOn (DeviceIntPtr); static Bool DeviceOff (DeviceIntPtr); static Bool DeviceClose (DeviceIntPtr); static Bool DeviceInit (DeviceIntPtr); -static void ReadInput (LocalDevicePtr); -static void CloseProc (LocalDevicePtr); -static Bool ConvertProc (LocalDevicePtr, int, int, int, int, int, int, int, int, int *, int *); -static Bool ReverseConvertProc(LocalDevicePtr , int , int , int*); +static void ReadInput (InputInfoPtr); +static void CloseProc (InputInfoPtr); +static Bool ConvertProc (InputInfoPtr, int, int, int, int, int, int, int, int, int *, int *); +static Bool ReverseConvertProc(InputInfoPtr , int , int , int*); static Bool QueryHardware (AceCadPrivatePtr); static void NewPacket (AceCadPrivatePtr priv); static Bool AceCadGetPacket (AceCadPrivatePtr); static InputInfoPtr AceCadPreInit(InputDriverPtr, IDevPtr , int); #ifdef HAVE_LINUX_INPUT_H -static void USBReadInput (LocalDevicePtr); -static Bool USBQueryHardware (LocalDevicePtr); +static void USBReadInput (InputInfoPtr); +static Bool USBQueryHardware (InputInfoPtr); static int IsUSBLine(int); static Bool fd_query_acecad(int, char*); -static Bool AceCadAutoDevProbe(LocalDevicePtr, int); +static Bool AceCadAutoDevProbe(InputInfoPtr, int); #endif - #endif -- cgit v1.2.3