summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/acecad.c31
-rw-r--r--src/acecad.h2
2 files changed, 16 insertions, 17 deletions
diff --git a/src/acecad.c b/src/acecad.c
index 6259f21..f5a2213 100644
--- a/src/acecad.c
+++ b/src/acecad.c
@@ -370,6 +370,21 @@ SetupProc_fail:
return NULL;
}
+static Bool
+ReverseConvertProc (InputInfoPtr local,
+ int x, int y,
+ int *valuators)
+{
+ AceCadPrivatePtr priv = (AceCadPrivatePtr)(local->private);
+
+ // xf86Msg(X_INFO, "%s: reverse coordinate conversion in : %d, %d\n", local->name, x, y);
+ valuators[0] = x * priv->acecadMaxX / screenInfo.screens[0]->width;
+ valuators[1] = y * priv->acecadMaxY / screenInfo.screens[0]->height;
+ // xf86Msg(X_INFO, "%s: reverse coordinate conversion out: %d, %d\n", local->name, valuators[0], valuators[1]);
+
+ return TRUE;
+}
+
static int
NewAceCadPreInit(InputDriverPtr drv, InputInfoPtr local, int flags)
#else
@@ -1071,22 +1086,6 @@ ConvertProc (InputInfoPtr local, int first, int num,
}
-static Bool
-ReverseConvertProc (InputInfoPtr local,
- int x, int y,
- int *valuators)
-{
- AceCadPrivatePtr priv = (AceCadPrivatePtr)(local->private);
-
- // xf86Msg(X_INFO, "%s: reverse coordinate conversion in : %d, %d\n", local->name, x, y);
- valuators[0] = x * priv->acecadMaxX / screenInfo.screens[0]->width;
- valuators[1] = y * priv->acecadMaxY / screenInfo.screens[0]->height;
- // xf86Msg(X_INFO, "%s: reverse coordinate conversion out: %d, %d\n", local->name, valuators[0], valuators[1]);
-
- return TRUE;
-}
-
-
#define WriteString(str)\
XisbWrite (priv->buffer, (unsigned char *)(str), strlen(str))
diff --git a/src/acecad.h b/src/acecad.h
index a2b5c66..bd8e997 100644
--- a/src/acecad.h
+++ b/src/acecad.h
@@ -102,12 +102,12 @@ static Bool DeviceClose (DeviceIntPtr);
static Bool DeviceInit (DeviceIntPtr);
static void ReadInput (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);
#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) < 12
static InputInfoPtr AceCadPreInit(InputDriverPtr, IDevPtr , int);
+static Bool ReverseConvertProc(InputInfoPtr , int , int , int*);
#else
static int AceCadPreInit(InputDriverPtr, InputInfoPtr , int);
#endif