Hi,
It's the last part of "rename xf86Wcm* to wcm*" story.
There are a few more remaining, but only in xf86Msg calls:
src/wcmCommon.c:xf86Msg(X_ERROR, "Wacom xf86WcmWrite error : %s\n",
strerror(errno));
src/wcmISDV4.c: xf86Msg(X_WARNING, "%s: xf86WcmWrite ISDV4_STOP error :
%s\n",
src/wcmISDV4.c: xf86Msg(X_WARNING, "%s: unable to xf86WcmWrite request %
s "
src/wcmISDV4.c: xf86Msg(X_ERROR, "%s: xf86WcmWrite error : %s\n",
local->name, strerror(errno));
src/wcmISDV4.c: xf86Msg(X_ERROR, "Wacom xf86WcmRead error : %s\n",
src/xf86Wacom.h: * xf86WcmRead() returns -1 AND errno is left as EINTR
from hell knows where.
I'm not fixing them now, because I'm not sure "what author wants to say"
--
Przemo
>From 4905abf87fcba1170783fe166cd8590cc6b2cdc8 Mon Sep 17 00:00:00 2001
From: Przemo Firszt <[email protected]>
Date: Sun, 24 Jan 2010 16:53:58 +0000
Subject: [PATCH 2/2] Rename xf86Wcm* to wcm* - part 3
xf86WcmInitialToolSize -> wcmInitialToolSize
xf86WcmSetPadCoreMode -> wcmSetPadCoreMode
xf86WcmDevSwitchModeCall -> wcmDevSwitchModeCall
xf86WcmChangeScreen -> wcmChangeScreen
xf86WcmInitialCoordinates -> wcmInitialCoordinates
xf86WcmVirtualTabletSize -> wcmVirtualTabletSize
xf86WcmSendButtons -> wcmSendButtons
xf86WcmVirtualTabletPadding -> wcmVirtualTabletPadding
xf86WcmFingerTapToClick -> wcmFingerTapToClick
xf86WcmSetScreen -> wcmSetScreen
xf86WcmAllocate -> wcmAllocate
xf86WcmInitialTVScreens -> wcmInitialTVScreens
xf86WcmSendEvents -> wcmSendEvents
xf86WcmDevConvert -> wcmDevConvert
xf86WcmDevReverseConvert -> wcmDevReverseConvert
xf86WcmDevProc -> wcmDevProc
xf86WcmDevControlProc -> wcmDevControlProc
xf86WcmDevChangeControl -> wcmDevChangeControl
xf86WcmDevOpen -> wcmDevOpen
xf86WcmInitTablet -> wcmInitTablet
xf86WcmDevSwitchMode -> wcmDevSwitchMode
xf86WcmSetProperty -> wcmSetProperty
xf86WcmReady -> wcmReady
xf86WcmDevReadInput -> wcmDevReadInput
xf86WcmDevClose -> wcmDevClose
xf86WcmOpen -> wcmOpen
xf86WcmInitArea -> wcmInitArea
xf86WcmRegisterX11Devices -> wcmRegisterX11Devices
xf86WcmKbdCtrlCallback -> wcmKbdCtrlCallback
xf86WcmBellCallback -> wcmBellCallback
xf86WcmKbdLedCallback -> wcmKbdLedCallback
xf86WcmCheckSource -> wcmCheckSource
xf86WcmFingerZoom -> wcmFingerZoom
xf86WcmFingerScroll -> wcmFingerScroll
xf86WcmSwitchLeftClick -> wcmSwitchLeftClick
xf86WcmSendVerticalScrollEvent -> wcmSendVerticalScrollEvent
xf86WcmSendHorizontalScrollEvent -> wcmSendHorizontalScrollEvent
xf86WcmUninit -> wcmUninit
xf86WcmInit -> wcmInit
xf86WcmMatchDevice -> wcmMatchDevice
xf86WcmVersionRec -> wcmVersionRec
xf86WcmPlug -> wcmPlug
xf86Wcmplug -> wcmUnplug
Signed-off-by: Przemo Firszt <[email protected]>
---
src/wcmCommon.c | 76 ++++++++++++------------
src/wcmConfig.c | 54 +++++++++---------
src/wcmTouchFilter.c | 32 +++++-----
src/wcmValidateDevice.c | 8 +-
src/wcmXCommand.c | 54 +++++++++---------
src/xf86Wacom.c | 150 +++++++++++++++++++++++-----------------------
src/xf86Wacom.h | 6 +-
7 files changed, 190 insertions(+), 190 deletions(-)
diff --git a/src/wcmCommon.c b/src/wcmCommon.c
index 32ad82e..4ef4071 100644
--- a/src/wcmCommon.c
+++ b/src/wcmCommon.c
@@ -29,13 +29,13 @@ void wcmInitialScreens(LocalDevicePtr local);
void wcmRotateTablet(LocalDevicePtr local, int value);
void wcmRotateCoordinates(LocalDevicePtr local, int* x, int* y);
-extern int xf86WcmDevSwitchModeCall(LocalDevicePtr local, int mode);
-extern void xf86WcmChangeScreen(LocalDevicePtr local, int value);
-extern void xf86WcmInitialCoordinates(LocalDevicePtr local, int axes);
-extern void xf86WcmVirtualTabletSize(LocalDevicePtr local);
-extern void xf86WcmVirtualTabletPadding(LocalDevicePtr local);
+extern int wcmDevSwitchModeCall(LocalDevicePtr local, int mode);
+extern void wcmChangeScreen(LocalDevicePtr local, int value);
+extern void wcmInitialCoordinates(LocalDevicePtr local, int axes);
+extern void wcmVirtualTabletSize(LocalDevicePtr local);
+extern void wcmVirtualTabletPadding(LocalDevicePtr local);
extern void wcmTilt2R(WacomDeviceStatePtr ds);
-extern void xf86WcmFingerTapToClick(WacomCommonPtr common);
+extern void wcmFingerTapToClick(WacomCommonPtr common);
/*****************************************************************************
* Static functions
@@ -60,7 +60,7 @@ void wcmMappingFactor(LocalDevicePtr local)
DBG(10, priv, "\n"); /* just prints function name */
- xf86WcmVirtualTabletSize(local);
+ wcmVirtualTabletSize(local);
if (!(priv->flags & ABSOLUTE_FLAG) || !priv->wcmMMonitor)
{
@@ -95,14 +95,14 @@ void wcmMappingFactor(LocalDevicePtr local)
}
/*****************************************************************************
- * xf86WcmSetScreen --
+ * wcmSetScreen --
* set to the proper screen according to the converted (x,y).
* this only supports for horizontal setup now.
* need to know screen's origin (x,y) to support
* combined horizontal and vertical setups
****************************************************************************/
-static void xf86WcmSetScreen(LocalDevicePtr local, int v0, int v1)
+static void wcmSetScreen(LocalDevicePtr local, int v0, int v1)
{
WacomDevicePtr priv = (WacomDevicePtr) local->private;
int screenToSet = -1, i, j, x, y, tabletSize = 0;
@@ -112,7 +112,7 @@ static void xf86WcmSetScreen(LocalDevicePtr local, int v0, int v1)
if (priv->screen_no != -1 && priv->screen_no >= priv->numScreen)
{
- xf86Msg(X_ERROR, "%s: xf86WcmSetScreen Screen%d is larger than number of available screens (%d)\n",
+ xf86Msg(X_ERROR, "%s: wcmSetScreen Screen%d is larger than number of available screens (%d)\n",
local->name, priv->screen_no, priv->numScreen);
priv->screen_no = -1;
}
@@ -201,7 +201,7 @@ static void xf86WcmSetScreen(LocalDevicePtr local, int v0, int v1)
return;
}
- xf86WcmVirtualTabletPadding(local);
+ wcmVirtualTabletPadding(local);
x = ((double)(v0 + priv->leftPadding) * priv->factorX) - priv->screenTopX[screenToSet] + 0.5;
y = ((double)(v1 + priv->topPadding) * priv->factorY) - priv->screenTopY[screenToSet] + 0.5;
@@ -217,12 +217,12 @@ static void xf86WcmSetScreen(LocalDevicePtr local, int v0, int v1)
}
/*****************************************************************************
- * xf86WcmSendButtons --
+ * wcmSendButtons --
* Send button events by comparing the current button mask with the
* previous one.
****************************************************************************/
-static void xf86WcmSendButtons(LocalDevicePtr local, int buttons, int rx, int ry,
+static void wcmSendButtons(LocalDevicePtr local, int buttons, int rx, int ry,
int rz, int v3, int v4, int v5)
{
int button, mask;
@@ -409,7 +409,7 @@ static void toggleDisplay(LocalDevicePtr local)
int screen = tmppriv->screen_no;
if (++screen >= tmppriv->numScreen)
screen = -1;
- xf86WcmChangeScreen(tmppriv->local, screen);
+ wcmChangeScreen(tmppriv->local, screen);
}
}
}
@@ -418,7 +418,7 @@ static void toggleDisplay(LocalDevicePtr local)
int screen = priv->screen_no;
if (++screen >= priv->numScreen)
screen = -1;
- xf86WcmChangeScreen(local, screen);
+ wcmChangeScreen(local, screen);
}
}
}
@@ -444,7 +444,7 @@ static int countPresses(int keybtn, unsigned int* keys, int size)
/*****************************************************************************
* sendAButton --
- * Send one button event, called by xf86WcmSendButtons
+ * Send one button event, called by wcmSendButtons
****************************************************************************/
static void sendAButton(LocalDevicePtr local, int button, int mask,
int rx, int ry, int rz, int v3, int v4, int v5)
@@ -504,7 +504,7 @@ static void sendAButton(LocalDevicePtr local, int button, int mask,
break;
case AC_MODETOGGLE:
if (mask)
- xf86WcmDevSwitchModeCall(local,
+ wcmDevSwitchModeCall(local,
(is_absolute) ? Relative : Absolute); /* not a typo! */
break;
/* FIXME: this should be implemented as 4 values,
@@ -705,7 +705,7 @@ static void sendCommonEvents(LocalDevicePtr local, const WacomDeviceState* ds, i
/* send button events when state changed or first time in prox and button unpresses */
if (priv->oldButtons != buttons || (!priv->oldProximity && !buttons))
- xf86WcmSendButtons(local,buttons,x,y,z,v3,v4,v5);
+ wcmSendButtons(local,buttons,x,y,z,v3,v4,v5);
/* emulate wheel/strip events when defined */
if ( ds->relwheel || ds->abswheel ||
@@ -742,11 +742,11 @@ void wcmRotateCoordinates(LocalDevicePtr local, int* x, int* y)
}
/*****************************************************************************
- * xf86WcmSendEvents --
+ * wcmSendEvents --
* Send events according to the device state.
****************************************************************************/
-void xf86WcmSendEvents(LocalDevicePtr local, const WacomDeviceState* ds)
+void wcmSendEvents(LocalDevicePtr local, const WacomDeviceState* ds)
{
#ifdef DEBUG
int is_button = !!(ds->buttons);
@@ -858,7 +858,7 @@ void xf86WcmSendEvents(LocalDevicePtr local, const WacomDeviceState* ds)
* screen and modify the axes before posting events */
if(!(priv->flags & BUTTONS_ONLY_FLAG))
{
- xf86WcmSetScreen(local, x, y);
+ wcmSetScreen(local, x, y);
}
/* unify acceleration in both directions
@@ -869,14 +869,14 @@ void xf86WcmSendEvents(LocalDevicePtr local, const WacomDeviceState* ds)
else
{
/* Padding virtual values */
- xf86WcmVirtualTabletPadding(local);
+ wcmVirtualTabletPadding(local);
x += priv->leftPadding;
y += priv->topPadding;
}
if (common->wcmScaling)
{
- /* In the case that xf86WcmDevConvert doesn't get called.
+ /* In the case that wcmDevConvert doesn't get called.
* The +-0.4 is to increase the sensitivity in relative mode.
* Must be sensitive to which way the tool is moved or one way
* will get a severe penalty for small movements.
@@ -932,7 +932,7 @@ void xf86WcmSendEvents(LocalDevicePtr local, const WacomDeviceState* ds)
if (common->wcmScaling)
{
- /* In the case that xf86WcmDevConvert doesn't called */
+ /* In the case that wcmDevConvert doesn't called */
x = priv->currentSX;
y = priv->currentSY;
}
@@ -940,7 +940,7 @@ void xf86WcmSendEvents(LocalDevicePtr local, const WacomDeviceState* ds)
/* reports button up when the device has been
* down and becomes out of proximity */
if (priv->oldButtons)
- xf86WcmSendButtons(local,0,x,y,z,v3,v4,v5);
+ wcmSendButtons(local,0,x,y,z,v3,v4,v5);
if (priv->oldProximity && local->dev->proximity)
xf86PostProximityEvent(local->dev,0,0,naxes,x,y,z,v3,v4,v5);
@@ -953,7 +953,7 @@ void xf86WcmSendEvents(LocalDevicePtr local, const WacomDeviceState* ds)
x = 0;
y = 0;
if ( v3 || v4 || v5 )
- xf86WcmSetScreen(local, x, y);
+ wcmSetScreen(local, x, y);
/* don't emit proximity events if device does not support proximity */
if ((local->dev->proximity && !priv->oldProximity))
@@ -973,7 +973,7 @@ void xf86WcmSendEvents(LocalDevicePtr local, const WacomDeviceState* ds)
else
{
if (priv->oldButtons)
- xf86WcmSendButtons(local, buttons,
+ wcmSendButtons(local, buttons,
x, y, z, v3, v4, v5);
if (priv->oldProximity && local->dev->proximity)
xf86PostProximityEvent(local->dev, 0, 0, naxes,
@@ -1239,7 +1239,7 @@ void wcmEvent(WacomCommonPtr common, unsigned int channel,
/* process gesture */
if (channel)
{
- xf86WcmFingerTapToClick(common);
+ wcmFingerTapToClick(common);
goto ret;
}
}
@@ -1395,7 +1395,7 @@ static void commonDispatchDevice(WacomCommonPtr common, unsigned int channel,
out.device_type = DEVICE_ID(((WacomDevicePtr)(oDev->private))->flags);
DBG(2, common, "Soft prox-out for %s\n",
outprox->device->name);
- xf86WcmSendEvents(oDev, &out);
+ wcmSendEvents(oDev, &out);
}
else
tool->current = outprox;
@@ -1466,7 +1466,7 @@ static void commonDispatchDevice(WacomCommonPtr common, unsigned int channel,
DBG(2, common,
"Send soft prox-out for %s first\n",
localDevices->name);
- xf86WcmSendEvents(localDevices, &out);
+ wcmSendEvents(localDevices, &out);
}
}
}
@@ -1590,7 +1590,7 @@ static void commonDispatchDevice(WacomCommonPtr common, unsigned int channel,
return;
}
}
- xf86WcmSendEvents(pDev, &filtered);
+ wcmSendEvents(pDev, &filtered);
/* If out-prox, reset the current area pointer */
if (!filtered.proximity)
tool->current = NULL;
@@ -1606,10 +1606,10 @@ static void commonDispatchDevice(WacomCommonPtr common, unsigned int channel,
}
/*****************************************************************************
- * xf86WcmInitTablet -- common initialization for all tablets
+ * wcmInitTablet -- common initialization for all tablets
****************************************************************************/
-int xf86WcmInitTablet(LocalDevicePtr local, const char* id, float version)
+int wcmInitTablet(LocalDevicePtr local, const char* id, float version)
{
WacomDevicePtr priv = (WacomDevicePtr)local->private;
WacomCommonPtr common = priv->common;
@@ -1702,10 +1702,10 @@ static void transPressureCurve(WacomDevicePtr pDev, WacomDeviceStatePtr pState)
}
/*****************************************************************************
- * xf86WcmInitialTVScreens
+ * wcmInitialTVScreens
****************************************************************************/
-static void xf86WcmInitialTVScreens(LocalDevicePtr local)
+static void wcmInitialTVScreens(LocalDevicePtr local)
{
WacomDevicePtr priv = (WacomDevicePtr)local->private;
@@ -1820,7 +1820,7 @@ void wcmInitialScreens(LocalDevicePtr local)
priv->tvoffsetY = 0;
if (priv->twinview != TV_NONE)
{
- xf86WcmInitialTVScreens(local);
+ wcmInitialTVScreens(local);
return;
}
@@ -1900,8 +1900,8 @@ static void rotateOneTool(WacomDevicePtr priv)
area->bottomY = priv->bottomY = oldMaxY - tmpTopY;
break;
}
- xf86WcmInitialCoordinates(priv->local, 0);
- xf86WcmInitialCoordinates(priv->local, 1);
+ wcmInitialCoordinates(priv->local, 0);
+ wcmInitialCoordinates(priv->local, 1);
if (tmpTopX != priv->topX)
xf86ReplaceIntOption(priv->local->options, "TopX", priv->topX);
diff --git a/src/wcmConfig.c b/src/wcmConfig.c
index feb17b4..30dafe1 100644
--- a/src/wcmConfig.c
+++ b/src/wcmConfig.c
@@ -36,13 +36,13 @@ extern int wcmParseOptions(LocalDevicePtr local, unsigned long* keys);
extern void wcmHotplugOthers(LocalDevicePtr local, unsigned long* keys);
extern int wcmDeviceTypeKeys(LocalDevicePtr local, unsigned long* keys);
-static int xf86WcmAllocate(LocalDevicePtr local, char* name, int flag);
+static int wcmAllocate(LocalDevicePtr local, char* name, int flag);
/*****************************************************************************
- * xf86WcmAllocate --
+ * wcmAllocate --
****************************************************************************/
-static int xf86WcmAllocate(LocalDevicePtr local, char* type_name, int flag)
+static int wcmAllocate(LocalDevicePtr local, char* type_name, int flag)
{
WacomDevicePtr priv = NULL;
WacomCommonPtr common = NULL;
@@ -175,7 +175,7 @@ error:
return 0;
}
-static int xf86WcmAllocateByType(LocalDevicePtr local, const char *type)
+static int wcmAllocateByType(LocalDevicePtr local, const char *type)
{
int rc = 0;
@@ -188,15 +188,15 @@ static int xf86WcmAllocateByType(LocalDevicePtr local, const char *type)
}
if (xf86NameCmp(type, "stylus") == 0)
- rc = xf86WcmAllocate(local, XI_STYLUS, ABSOLUTE_FLAG|STYLUS_ID);
+ rc = wcmAllocate(local, XI_STYLUS, ABSOLUTE_FLAG|STYLUS_ID);
else if (xf86NameCmp(type, "touch") == 0)
- rc = xf86WcmAllocate(local, XI_TOUCH, ABSOLUTE_FLAG|TOUCH_ID);
+ rc = wcmAllocate(local, XI_TOUCH, ABSOLUTE_FLAG|TOUCH_ID);
else if (xf86NameCmp(type, "cursor") == 0)
- rc = xf86WcmAllocate(local, XI_CURSOR, CURSOR_ID);
+ rc = wcmAllocate(local, XI_CURSOR, CURSOR_ID);
else if (xf86NameCmp(type, "eraser") == 0)
- rc = xf86WcmAllocate(local, XI_ERASER, ABSOLUTE_FLAG|ERASER_ID);
+ rc = wcmAllocate(local, XI_ERASER, ABSOLUTE_FLAG|ERASER_ID);
else if (xf86NameCmp(type, "pad") == 0)
- rc = xf86WcmAllocate(local, XI_PAD, PAD_ID);
+ rc = wcmAllocate(local, XI_PAD, PAD_ID);
return rc;
}
@@ -221,9 +221,9 @@ static const char *default_options[] =
NULL
};
-/* xf86WcmUninit - called when the device is no longer needed. */
+/* wcmUninit - called when the device is no longer needed. */
-static void xf86WcmUninit(InputDriverPtr drv, LocalDevicePtr local, int flags)
+static void wcmUninit(InputDriverPtr drv, LocalDevicePtr local, int flags)
{
WacomDevicePtr priv = (WacomDevicePtr) local->private;
WacomDevicePtr dev;
@@ -276,9 +276,9 @@ static void xf86WcmUninit(InputDriverPtr drv, LocalDevicePtr local, int flags)
xf86DeleteInput(local, 0);
}
-/* xf86WcmMatchDevice - locate matching device and merge common structure */
+/* wcmMatchDevice - locate matching device and merge common structure */
-static Bool xf86WcmMatchDevice(LocalDevicePtr pMatch, LocalDevicePtr pLocal)
+static Bool wcmMatchDevice(LocalDevicePtr pMatch, LocalDevicePtr pLocal)
{
WacomDevicePtr privMatch = (WacomDevicePtr)pMatch->private;
WacomDevicePtr priv = (WacomDevicePtr)pLocal->private;
@@ -311,9 +311,9 @@ static Bool xf86WcmMatchDevice(LocalDevicePtr pMatch, LocalDevicePtr pLocal)
return 0;
}
-/* xf86WcmInit - called for each input devices with the driver set to
+/* wcmInit - called for each input devices with the driver set to
* "wacom" */
-static LocalDevicePtr xf86WcmInit(InputDriverPtr drv, IDevPtr dev, int flags)
+static LocalDevicePtr wcmInit(InputDriverPtr drv, IDevPtr dev, int flags)
{
LocalDevicePtr local = NULL;
WacomDevicePtr priv = NULL;
@@ -356,7 +356,7 @@ static LocalDevicePtr xf86WcmInit(InputDriverPtr drv, IDevPtr dev, int flags)
goto SetupProc_fail;
}
- if (!xf86WcmAllocateByType(local, type))
+ if (!wcmAllocateByType(local, type))
goto SetupProc_fail;
priv = (WacomDevicePtr) local->private;
@@ -376,7 +376,7 @@ static LocalDevicePtr xf86WcmInit(InputDriverPtr drv, IDevPtr dev, int flags)
LocalDevicePtr localDevices = xf86FirstLocalDevice();
for (; localDevices != NULL; localDevices = localDevices->next)
{
- if (xf86WcmMatchDevice(localDevices,local))
+ if (wcmMatchDevice(localDevices,local))
{
common = priv->common;
break;
@@ -421,29 +421,29 @@ InputDriverRec WACOM =
1, /* driver version */
"wacom", /* driver name */
NULL, /* identify */
- xf86WcmInit, /* pre-init */
- xf86WcmUninit, /* un-init */
+ wcmInit, /* pre-init */
+ wcmUninit, /* un-init */
NULL, /* module */
0 /* ref count */
};
-/* xf86WcmUnplug - Uninitialize the device */
+/* wcmUnplug - Uninitialize the device */
-static void xf86WcmUnplug(pointer p)
+static void wcmUnplug(pointer p)
{
}
-/* xf86WcmPlug - called by the module loader */
+/* wcmPlug - called by the module loader */
-static pointer xf86WcmPlug(pointer module, pointer options, int* errmaj,
+static pointer wcmPlug(pointer module, pointer options, int* errmaj,
int* errmin)
{
xf86AddInputDriver(&WACOM, module, 0);
return module;
}
-static XF86ModuleVersionInfo xf86WcmVersionRec =
+static XF86ModuleVersionInfo wcmVersionRec =
{
"wacom",
MODULEVENDORSTRING,
@@ -459,9 +459,9 @@ static XF86ModuleVersionInfo xf86WcmVersionRec =
_X_EXPORT XF86ModuleData wacomModuleData =
{
- &xf86WcmVersionRec,
- xf86WcmPlug,
- xf86WcmUnplug
+ &wcmVersionRec,
+ wcmPlug,
+ wcmUnplug
};
/* vim: set noexpandtab shiftwidth=8: */
diff --git a/src/wcmTouchFilter.c b/src/wcmTouchFilter.c
index 2b069c0..b91b14a 100644
--- a/src/wcmTouchFilter.c
+++ b/src/wcmTouchFilter.c
@@ -42,13 +42,13 @@
/* Defines for Tap Add-a-Finger to Click */
#define WACOM_TAP_TIME_IN_MS 150
-void xf86WcmFingerTapToClick(WacomCommonPtr common);
+void wcmFingerTapToClick(WacomCommonPtr common);
extern void wcmRotateCoordinates(LocalDevicePtr local, int* x, int* y);
extern void emitKeysym (DeviceIntPtr keydev, int keysym, int state);
-static void xf86WcmFingerScroll(WacomDevicePtr priv);
-static void xf86WcmFingerZoom(WacomDevicePtr priv);
+static void wcmFingerScroll(WacomDevicePtr priv);
+static void wcmFingerZoom(WacomDevicePtr priv);
static double touchDistance(WacomDeviceState ds0, WacomDeviceState ds1)
{
@@ -99,7 +99,7 @@ static Bool pointsInLineAfter(int p1, int p2)
return ret;
}
-static void xf86WcmSwitchLeftClick(WacomDevicePtr priv)
+static void wcmSwitchLeftClick(WacomDevicePtr priv)
{
WacomCommonPtr common = priv->common;
@@ -118,7 +118,7 @@ static void xf86WcmSwitchLeftClick(WacomDevicePtr priv)
* translate second finger tap to right click
****************************************************************************/
-void xf86WcmFingerTapToClick(WacomCommonPtr common)
+void wcmFingerTapToClick(WacomCommonPtr common)
{
WacomDevicePtr priv = common->wcmDevices;
WacomChannelPtr firstChannel = common->wcmChannel;
@@ -159,7 +159,7 @@ void xf86WcmFingerTapToClick(WacomCommonPtr common)
if (!common->wcmGestureMode)
{
common->wcmGestureMode = GESTURE_TAP_MODE;
- xf86WcmSwitchLeftClick(priv);
+ wcmSwitchLeftClick(priv);
}
/* right button down */
@@ -188,9 +188,9 @@ void xf86WcmFingerTapToClick(WacomCommonPtr common)
if (!common->wcmGestureMode)
{
common->wcmGestureMode = GESTURE_ZOOM_MODE;
- xf86WcmSwitchLeftClick(priv);
+ wcmSwitchLeftClick(priv);
}
- xf86WcmFingerZoom(priv);
+ wcmFingerZoom(priv);
}
if ( pointsInLine(ds[0], dsLast[0], &direction) &&
@@ -203,9 +203,9 @@ void xf86WcmFingerTapToClick(WacomCommonPtr common)
if (!common->wcmGestureMode)
{
common->wcmGestureMode = GESTURE_SCROLL_MODE;
- xf86WcmSwitchLeftClick(priv);
+ wcmSwitchLeftClick(priv);
}
- xf86WcmFingerScroll(priv);
+ wcmFingerScroll(priv);
}
}
}
@@ -227,7 +227,7 @@ skipGesture:
}
}
-static void xf86WcmSendVerticalScrollEvent(WacomDevicePtr priv,
+static void wcmSendVerticalScrollEvent(WacomDevicePtr priv,
int dist, int up, int dn)
{
int i = 0;
@@ -264,7 +264,7 @@ static void xf86WcmSendVerticalScrollEvent(WacomDevicePtr priv,
}
}
-static void xf86WcmSendHorizontalScrollEvent(WacomDevicePtr priv,
+static void wcmSendHorizontalScrollEvent(WacomDevicePtr priv,
int dist, int left, int right)
{
int i = 0;
@@ -301,7 +301,7 @@ static void xf86WcmSendHorizontalScrollEvent(WacomDevicePtr priv,
}
}
-static void xf86WcmFingerScroll(WacomDevicePtr priv)
+static void wcmFingerScroll(WacomDevicePtr priv)
{
WacomCommonPtr common = priv->common;
WacomChannelPtr firstChannel = common->wcmChannel;
@@ -348,7 +348,7 @@ static void xf86WcmFingerScroll(WacomDevicePtr priv)
if (abs(dist) > WACOM_PARA_MOTION_IN_POINT)
{
gesture = 1;
- xf86WcmSendVerticalScrollEvent(priv, dist,
+ wcmSendVerticalScrollEvent(priv, dist,
WCM_SCROLL_UP, WCM_SCROLL_DOWN);
}
@@ -366,7 +366,7 @@ static void xf86WcmFingerScroll(WacomDevicePtr priv)
if (abs(dist) > WACOM_PARA_MOTION_IN_POINT)
{
gesture = 1;
- xf86WcmSendHorizontalScrollEvent(priv, dist,
+ wcmSendHorizontalScrollEvent(priv, dist,
WCM_SCROLL_LEFT, WCM_SCROLL_RIGHT);
}
}
@@ -380,7 +380,7 @@ static void xf86WcmFingerScroll(WacomDevicePtr priv)
}
}
-static void xf86WcmFingerZoom(WacomDevicePtr priv)
+static void wcmFingerZoom(WacomDevicePtr priv)
{
WacomCommonPtr common = priv->common;
WacomChannelPtr firstChannel = common->wcmChannel;
diff --git a/src/wcmValidateDevice.c b/src/wcmValidateDevice.c
index 07f3bcc..088365e 100644
--- a/src/wcmValidateDevice.c
+++ b/src/wcmValidateDevice.c
@@ -38,11 +38,11 @@ int wcmParseOptions(LocalDevicePtr local, unsigned long* keys);
int wcmIsDuplicate(char* device, LocalDevicePtr local);
int wcmDeviceTypeKeys(LocalDevicePtr local, unsigned long* keys);
-/* xf86WcmCheckSource - Check if there is another source defined this device
+/* wcmCheckSource - Check if there is another source defined this device
* before or not: don't add the tool by hal/udev if user has defined at least
* one tool for the device in xorg.conf. One device can have multiple tools
* with the same type to individualize tools with serial number or areas */
-static Bool xf86WcmCheckSource(LocalDevicePtr local, dev_t min_maj)
+static Bool wcmCheckSource(LocalDevicePtr local, dev_t min_maj)
{
int match = 0;
char* device;
@@ -122,7 +122,7 @@ int wcmIsDuplicate(char* device, LocalDevicePtr local)
if (st.st_rdev)
{
/* device matches with another added port */
- if (xf86WcmCheckSource(local, st.st_rdev))
+ if (wcmCheckSource(local, st.st_rdev))
{
isInUse = 3;
goto ret;
@@ -441,7 +441,7 @@ int wcmParseOptions(LocalDevicePtr local, unsigned long* keys)
* Always in absolute mode when it is not a core device.
*/
if (IsPad(priv))
- xf86WcmSetPadCoreMode(local);
+ wcmSetPadCoreMode(local);
/* Store original local Core flag so it can be changed later */
if (local->flags & (XI86_ALWAYS_CORE | XI86_CORE_POINTER))
diff --git a/src/wcmXCommand.c b/src/wcmXCommand.c
index 41f0051..597160a 100644
--- a/src/wcmXCommand.c
+++ b/src/wcmXCommand.c
@@ -24,25 +24,25 @@
#include "xf86Wacom.h"
#include "wcmFilter.h"
-extern void xf86WcmInitialCoordinates(LocalDevicePtr local, int axes);
+extern void wcmInitialCoordinates(LocalDevicePtr local, int axes);
extern void wcmRotateTablet(LocalDevicePtr local, int value);
extern void wcmInitialScreens(LocalDevicePtr local);
-int xf86WcmDevSwitchModeCall(LocalDevicePtr local, int mode);
-int xf86WcmDevSwitchMode(ClientPtr client, DeviceIntPtr dev, int mode);
-void xf86WcmChangeScreen(LocalDevicePtr local, int value);
+int wcmDevSwitchModeCall(LocalDevicePtr local, int mode);
+int wcmDevSwitchMode(ClientPtr client, DeviceIntPtr dev, int mode);
+void wcmChangeScreen(LocalDevicePtr local, int value);
#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) >= 3
- int xf86WcmSetProperty(DeviceIntPtr dev, Atom property,
+ int wcmSetProperty(DeviceIntPtr dev, Atom property,
XIPropertyValuePtr prop, BOOL checkonly);
void InitWcmDeviceProperties(LocalDevicePtr local);
#endif
/*****************************************************************************
- * xf86WcmSetPadCoreMode
+ * wcmSetPadCoreMode
****************************************************************************/
-int xf86WcmSetPadCoreMode(LocalDevicePtr local)
+int wcmSetPadCoreMode(LocalDevicePtr local)
{
WacomDevicePtr priv = (WacomDevicePtr)local->private;
int is_core = local->flags & (XI86_ALWAYS_CORE | XI86_CORE_POINTER);
@@ -63,10 +63,10 @@ int xf86WcmSetPadCoreMode(LocalDevicePtr local)
}
/*****************************************************************************
-* xf86WcmDevSwitchModeCall --
+* wcmDevSwitchModeCall --
*****************************************************************************/
-int xf86WcmDevSwitchModeCall(LocalDevicePtr local, int mode)
+int wcmDevSwitchModeCall(LocalDevicePtr local, int mode)
{
WacomDevicePtr priv = (WacomDevicePtr)local->private;
int is_absolute = priv->flags & ABSOLUTE_FLAG;
@@ -77,21 +77,21 @@ int xf86WcmDevSwitchModeCall(LocalDevicePtr local, int mode)
* Always in absolute mode when it is not a core device.
*/
if (IsPad(priv))
- return xf86WcmSetPadCoreMode(local);
+ return wcmSetPadCoreMode(local);
if ((mode == Absolute) && !is_absolute)
{
priv->flags |= ABSOLUTE_FLAG;
xf86ReplaceStrOption(local->options, "Mode", "Absolute");
- xf86WcmInitialCoordinates(local, 0);
- xf86WcmInitialCoordinates(local, 1);
+ wcmInitialCoordinates(local, 0);
+ wcmInitialCoordinates(local, 1);
}
else if ((mode == Relative) && is_absolute)
{
priv->flags &= ~ABSOLUTE_FLAG;
xf86ReplaceStrOption(local->options, "Mode", "Relative");
- xf86WcmInitialCoordinates(local, 0);
- xf86WcmInitialCoordinates(local, 1);
+ wcmInitialCoordinates(local, 0);
+ wcmInitialCoordinates(local, 1);
}
else if ( (mode != Absolute) && (mode != Relative))
{
@@ -103,10 +103,10 @@ int xf86WcmDevSwitchModeCall(LocalDevicePtr local, int mode)
}
/*****************************************************************************
-* xf86WcmDevSwitchMode --
+* wcmDevSwitchMode --
*****************************************************************************/
-int xf86WcmDevSwitchMode(ClientPtr client, DeviceIntPtr dev, int mode)
+int wcmDevSwitchMode(ClientPtr client, DeviceIntPtr dev, int mode)
{
LocalDevicePtr local = (LocalDevicePtr)dev->public.devicePrivate;
#ifdef DEBUG
@@ -116,14 +116,14 @@ int xf86WcmDevSwitchMode(ClientPtr client, DeviceIntPtr dev, int mode)
(void *)dev, mode);
#endif
/* Share this call with sendAButton in wcmCommon.c */
- return xf86WcmDevSwitchModeCall(local, mode);
+ return wcmDevSwitchModeCall(local, mode);
}
/*****************************************************************************
- * xf86WcmChangeScreen
+ * wcmChangeScreen
****************************************************************************/
-void xf86WcmChangeScreen(LocalDevicePtr local, int value)
+void wcmChangeScreen(LocalDevicePtr local, int value)
{
WacomDevicePtr priv = (WacomDevicePtr)local->private;
@@ -136,8 +136,8 @@ void xf86WcmChangeScreen(LocalDevicePtr local, int value)
if (priv->screen_no != -1)
priv->currentScreen = priv->screen_no;
wcmInitialScreens(local);
- xf86WcmInitialCoordinates(local, 0);
- xf86WcmInitialCoordinates(local, 1);
+ wcmInitialCoordinates(local, 0);
+ wcmInitialCoordinates(local, 1);
}
#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) >= 3
@@ -299,7 +299,7 @@ void InitWcmDeviceProperties(LocalDevicePtr local)
#endif
}
-int xf86WcmSetProperty(DeviceIntPtr dev, Atom property, XIPropertyValuePtr prop,
+int wcmSetProperty(DeviceIntPtr dev, Atom property, XIPropertyValuePtr prop,
BOOL checkonly)
{
LocalDevicePtr local = (LocalDevicePtr) dev->public.devicePrivate;
@@ -353,8 +353,8 @@ int xf86WcmSetProperty(DeviceIntPtr dev, Atom property, XIPropertyValuePtr prop,
priv->topY = area->topY = values[1];
priv->bottomX = area->bottomX = values[2];
priv->bottomY = area->bottomY = values[3];
- xf86WcmInitialCoordinates(local, 0);
- xf86WcmInitialCoordinates(local, 1);
+ wcmInitialCoordinates(local, 0);
+ wcmInitialCoordinates(local, 1);
}
} else if (property == prop_pressurecurve)
{
@@ -485,7 +485,7 @@ int xf86WcmSetProperty(DeviceIntPtr dev, Atom property, XIPropertyValuePtr prop,
if (!checkonly)
{
if (priv->screen_no != values[0])
- xf86WcmChangeScreen(local, values[0]);
+ wcmChangeScreen(local, values[0]);
priv->screen_no = values[0];
if (priv->twinview != values[1])
@@ -501,7 +501,7 @@ int xf86WcmSetProperty(DeviceIntPtr dev, Atom property, XIPropertyValuePtr prop,
DBG(10, priv, "TwinView sets to "
"TV_NONE: can't change screen_no. \n");
}
- xf86WcmChangeScreen(local, screen);
+ wcmChangeScreen(local, screen);
}
priv->wcmMMonitor = values[2];
@@ -600,7 +600,7 @@ int xf86WcmSetProperty(DeviceIntPtr dev, Atom property, XIPropertyValuePtr prop,
priv->tvResolution[3] = values[3];
/* reset screen info */
- xf86WcmChangeScreen(local, priv->screen_no);
+ wcmChangeScreen(local, priv->screen_no);
}
#ifdef DEBUG
} else if (property == prop_debuglevels)
diff --git a/src/xf86Wacom.c b/src/xf86Wacom.c
index 231325d..52315fe 100644
--- a/src/xf86Wacom.c
+++ b/src/xf86Wacom.c
@@ -51,31 +51,31 @@
#include <xkbsrv.h>
#endif
-void xf86WcmVirtualTabletPadding(LocalDevicePtr local);
-void xf86WcmVirtualTabletSize(LocalDevicePtr local);
+void wcmVirtualTabletPadding(LocalDevicePtr local);
+void wcmVirtualTabletSize(LocalDevicePtr local);
Bool wcmIsWacomDevice (char* fname);
#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) >= 3
extern void InitWcmDeviceProperties(LocalDevicePtr local);
- extern int xf86WcmSetProperty(DeviceIntPtr dev, Atom property, XIPropertyValuePtr prop,
+ extern int wcmSetProperty(DeviceIntPtr dev, Atom property, XIPropertyValuePtr prop,
BOOL checkonly);
#endif
-extern int xf86WcmDevSwitchMode(ClientPtr client, DeviceIntPtr dev, int mode);
+extern int wcmDevSwitchMode(ClientPtr client, DeviceIntPtr dev, int mode);
extern void wcmRotateTablet(LocalDevicePtr local, int value);
extern void wcmInitialScreens(LocalDevicePtr local);
-extern void xf86WcmInitialCoordinates(LocalDevicePtr local, int axes);
-
-static int xf86WcmDevOpen(DeviceIntPtr pWcm);
-static int xf86WcmReady(LocalDevicePtr local);
-static void xf86WcmDevReadInput(LocalDevicePtr local);
-static void xf86WcmDevControlProc(DeviceIntPtr device, PtrCtrl* ctrl);
-int xf86WcmDevChangeControl(LocalDevicePtr local, xDeviceCtl * control);
-static void xf86WcmDevClose(LocalDevicePtr local);
-static int xf86WcmDevProc(DeviceIntPtr pWcm, int what);
-static Bool xf86WcmDevConvert(LocalDevicePtr local, int first, int num,
+extern void wcmInitialCoordinates(LocalDevicePtr local, int axes);
+
+static int wcmDevOpen(DeviceIntPtr pWcm);
+static int wcmReady(LocalDevicePtr local);
+static void wcmDevReadInput(LocalDevicePtr local);
+static void wcmDevControlProc(DeviceIntPtr device, PtrCtrl* ctrl);
+int wcmDevChangeControl(LocalDevicePtr local, xDeviceCtl * control);
+static void wcmDevClose(LocalDevicePtr local);
+static int wcmDevProc(DeviceIntPtr pWcm, int what);
+static Bool wcmDevConvert(LocalDevicePtr local, int first, int num,
int v0, int v1, int v2, int v3, int v4, int v5, int* x, int* y);
-static Bool xf86WcmDevReverseConvert(LocalDevicePtr local, int x, int y,
+static Bool wcmDevReverseConvert(LocalDevicePtr local, int x, int y,
int* valuators);
WacomModule gWacomModule =
@@ -83,28 +83,28 @@ WacomModule gWacomModule =
NULL, /* input driver pointer */
/* device procedures */
- xf86WcmDevOpen,
- xf86WcmDevReadInput,
- xf86WcmDevControlProc,
- xf86WcmDevChangeControl,
- xf86WcmDevClose,
- xf86WcmDevProc,
- xf86WcmDevSwitchMode,
- xf86WcmDevConvert,
- xf86WcmDevReverseConvert,
+ wcmDevOpen,
+ wcmDevReadInput,
+ wcmDevControlProc,
+ wcmDevChangeControl,
+ wcmDevClose,
+ wcmDevProc,
+ wcmDevSwitchMode,
+ wcmDevConvert,
+ wcmDevReverseConvert,
};
-static void xf86WcmKbdLedCallback(DeviceIntPtr di, LedCtrl * lcp)
+static void wcmKbdLedCallback(DeviceIntPtr di, LedCtrl * lcp)
{
}
#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) < 5
-static void xf86WcmBellCallback(int pct, DeviceIntPtr di, pointer ctrl, int x)
+static void wcmBellCallback(int pct, DeviceIntPtr di, pointer ctrl, int x)
{
}
#endif
-static void xf86WcmKbdCtrlCallback(DeviceIntPtr di, KeybdCtrl* ctrl)
+static void wcmKbdCtrlCallback(DeviceIntPtr di, KeybdCtrl* ctrl)
{
}
@@ -140,7 +140,7 @@ static void wcmDesktopSize(LocalDevicePtr local)
priv->maxHeight = maxY - minY;
}
-static int xf86WcmInitArea(LocalDevicePtr local)
+static int wcmInitArea(LocalDevicePtr local)
{
WacomDevicePtr priv = (WacomDevicePtr)local->private;
WacomToolAreaPtr area = priv->toolarea, inlist;
@@ -265,10 +265,10 @@ static int xf86WcmInitArea(LocalDevicePtr local)
}
/*****************************************************************************
- * xf86WcmVirtualTabletPadding(LocalDevicePtr local)
+ * wcmVirtualTabletPadding(LocalDevicePtr local)
****************************************************************************/
-void xf86WcmVirtualTabletPadding(LocalDevicePtr local)
+void wcmVirtualTabletPadding(LocalDevicePtr local)
{
WacomDevicePtr priv = (WacomDevicePtr)local->private;
int i;
@@ -296,10 +296,10 @@ void xf86WcmVirtualTabletPadding(LocalDevicePtr local)
}
/*****************************************************************************
- * xf86WcmVirtualTabletSize(LocalDevicePtr local)
+ * wcmVirtualTabletSize(LocalDevicePtr local)
****************************************************************************/
-void xf86WcmVirtualTabletSize(LocalDevicePtr local)
+void wcmVirtualTabletSize(LocalDevicePtr local)
{
WacomDevicePtr priv = (WacomDevicePtr)local->private;
int i, tabletSize;
@@ -335,10 +335,10 @@ void xf86WcmVirtualTabletSize(LocalDevicePtr local)
}
/*****************************************************************************
- * xf86WcmInitialCoordinates
+ * wcmInitialCoordinates
****************************************************************************/
-void xf86WcmInitialCoordinates(LocalDevicePtr local, int axes)
+void wcmInitialCoordinates(LocalDevicePtr local, int axes)
{
WacomDevicePtr priv = (WacomDevicePtr)local->private;
WacomCommonPtr common = priv->common;
@@ -372,7 +372,7 @@ void xf86WcmInitialCoordinates(LocalDevicePtr local, int axes)
resolution = priv->resolX;
if (common->wcmScaling)
{
- /* In case xf86WcmDevConvert didn't get called */
+ /* In case wcmDevConvert didn't get called */
topx = 0;
bottomx = (int)((double)priv->sizeX * priv->factorX + 0.5);
resolution = (int)((double)resolution * priv->factorX + 0.5);
@@ -406,7 +406,7 @@ void xf86WcmInitialCoordinates(LocalDevicePtr local, int axes)
resolution = priv->resolY;
if (common->wcmScaling)
{
- /* In case xf86WcmDevConvert didn't get called */
+ /* In case wcmDevConvert didn't get called */
topy = 0;
bottomy = (int)((double)priv->sizeY * priv->factorY + 0.5);
resolution = (int)((double)resolution * priv->factorY + 0.5);
@@ -568,11 +568,11 @@ static struct { KeySym keysym; CARD8 mask; } keymod[] = {
#endif
/*****************************************************************************
- * xf86WcmInitialToolSize --
+ * wcmInitialToolSize --
* Initialize logical size and resolution for individual tool.
****************************************************************************/
-static void xf86WcmInitialToolSize(LocalDevicePtr local)
+static void wcmInitialToolSize(LocalDevicePtr local)
{
WacomDevicePtr priv = (WacomDevicePtr)local->private;
WacomCommonPtr common = priv->common;
@@ -612,11 +612,11 @@ static void xf86WcmInitialToolSize(LocalDevicePtr local)
}
/*****************************************************************************
- * xf86WcmRegisterX11Devices --
+ * wcmRegisterX11Devices --
* Register the X11 input devices with X11 core.
****************************************************************************/
-static int xf86WcmRegisterX11Devices (LocalDevicePtr local)
+static int wcmRegisterX11Devices (LocalDevicePtr local)
{
WacomDevicePtr priv = (WacomDevicePtr)local->private;
WacomCommonPtr common = priv->common;
@@ -671,7 +671,7 @@ static int xf86WcmRegisterX11Devices (LocalDevicePtr local)
}
if (InitPtrFeedbackClassDeviceStruct(local->dev,
- xf86WcmDevControlProc) == FALSE)
+ wcmDevControlProc) == FALSE)
{
xf86Msg(X_ERROR, "%s: unable to init ptr feedback\n", local->name);
return FALSE;
@@ -747,13 +747,13 @@ static int xf86WcmRegisterX11Devices (LocalDevicePtr local)
}
}
- if(InitKbdFeedbackClassDeviceStruct(local->dev, xf86WcmBellCallback,
- xf86WcmKbdCtrlCallback) == FALSE) {
+ if(InitKbdFeedbackClassDeviceStruct(local->dev, wcmBellCallback,
+ wcmKbdCtrlCallback) == FALSE) {
xf86Msg(X_ERROR, "%s: unable to init kbd feedback device struct\n", local->name);
return FALSE;
}
#elif GET_ABI_MAJOR(ABI_XINPUT_VERSION) >= 7
- if (InitKeyboardDeviceStruct(local->dev, NULL, NULL, xf86WcmKbdCtrlCallback)) {
+ if (InitKeyboardDeviceStruct(local->dev, NULL, NULL, wcmKbdCtrlCallback)) {
#define SYMS_PER_KEY 2
KeySymsRec syms;
CARD8 modmap[MAP_LENGTH];
@@ -774,15 +774,15 @@ static int xf86WcmRegisterX11Devices (LocalDevicePtr local)
return FALSE;
}
#endif
- if(InitLedFeedbackClassDeviceStruct (local->dev, xf86WcmKbdLedCallback) == FALSE) {
+ if(InitLedFeedbackClassDeviceStruct (local->dev, wcmKbdLedCallback) == FALSE) {
xf86Msg(X_ERROR, "%s: unable to init led feedback device struct\n", local->name);
return FALSE;
}
}
- xf86WcmInitialToolSize(local);
+ wcmInitialToolSize(local);
- if (xf86WcmInitArea(local) == FALSE)
+ if (wcmInitArea(local) == FALSE)
{
return FALSE;
}
@@ -881,7 +881,7 @@ static int xf86WcmRegisterX11Devices (LocalDevicePtr local)
#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) >= 3
InitWcmDeviceProperties(local);
- XIRegisterPropertyHandler(local->dev, xf86WcmSetProperty, NULL, NULL);
+ XIRegisterPropertyHandler(local->dev, wcmSetProperty, NULL, NULL);
#endif
return TRUE;
@@ -951,10 +951,10 @@ char *wcmEventAutoDevProbe (LocalDevicePtr local)
}
/*****************************************************************************
- * xf86WcmOpen --
+ * wcmOpen --
****************************************************************************/
-static Bool xf86WcmOpen(LocalDevicePtr local)
+static Bool wcmOpen(LocalDevicePtr local)
{
WacomDevicePtr priv = (WacomDevicePtr)local->private;
WacomCommonPtr common = priv->common;
@@ -993,7 +993,7 @@ static Bool xf86WcmOpen(LocalDevicePtr local)
common->wcmDevCls = &gWacomUSBDevice;
else
{
- xf86Msg(X_ERROR, "%s: xf86WcmOpen found undetectable "
+ xf86Msg(X_ERROR, "%s: wcmOpen found undetectable "
" %s \n", local->name, common->wcmDevice);
return !Success;
}
@@ -1001,7 +1001,7 @@ static Bool xf86WcmOpen(LocalDevicePtr local)
/* Initialize the tablet */
if(common->wcmDevCls->Init(local, id, &version) != Success ||
- xf86WcmInitTablet(local, id, version) != Success)
+ wcmInitTablet(local, id, version) != Success)
{
xf86CloseSerial(local->fd);
local->fd = -1;
@@ -1011,11 +1011,11 @@ static Bool xf86WcmOpen(LocalDevicePtr local)
}
/*****************************************************************************
- * xf86WcmDevOpen --
+ * wcmDevOpen --
* Open the physical device and init information structs.
****************************************************************************/
-static int xf86WcmDevOpen(DeviceIntPtr pWcm)
+static int wcmDevOpen(DeviceIntPtr pWcm)
{
LocalDevicePtr local = (LocalDevicePtr)pWcm->public.devicePrivate;
WacomDevicePtr priv = (WacomDevicePtr)local->private;
@@ -1036,7 +1036,7 @@ static int xf86WcmDevOpen(DeviceIntPtr pWcm)
!(common->wcmDevice = wcmEventAutoDevProbe (local)))
xf86Msg(X_ERROR, "%s: Cannot probe device\n", local->name);
- if ((xf86WcmOpen (local) != Success) || (local->fd < 0) ||
+ if ((wcmOpen (local) != Success) || (local->fd < 0) ||
!common->wcmDevice)
{
DBG(1, priv, "Failed to open "
@@ -1073,13 +1073,13 @@ static int xf86WcmDevOpen(DeviceIntPtr pWcm)
common->fd_refs++;
}
- if (!xf86WcmRegisterX11Devices (local))
+ if (!wcmRegisterX11Devices (local))
return FALSE;
return TRUE;
}
-static int xf86WcmReady(LocalDevicePtr local)
+static int wcmReady(LocalDevicePtr local)
{
#ifdef DEBUG
WacomDevicePtr priv = (WacomDevicePtr)local->private;
@@ -1093,11 +1093,11 @@ static int xf86WcmReady(LocalDevicePtr local)
}
/*****************************************************************************
- * xf86WcmDevReadInput --
+ * wcmDevReadInput --
* Read the device on IO signal
****************************************************************************/
-static void xf86WcmDevReadInput(LocalDevicePtr local)
+static void wcmDevReadInput(LocalDevicePtr local)
{
int loop=0;
#define MAX_READ_LOOPS 10
@@ -1109,7 +1109,7 @@ static void xf86WcmDevReadInput(LocalDevicePtr local)
for (loop=0; loop < MAX_READ_LOOPS; ++loop)
{
/* verify that there is still data in pipe */
- if (!xf86WcmReady(local)) break;
+ if (!wcmReady(local)) break;
/* dispatch */
common->wcmDevCls->Read(local);
@@ -1149,7 +1149,7 @@ void wcmReadPacket(LocalDevicePtr local)
for(; wDev; wDev = wDev->next)
{
if (wDev->local->fd >= 0)
- xf86WcmDevProc(wDev->local->dev, DEVICE_OFF);
+ wcmDevProc(wDev->local->dev, DEVICE_OFF);
}
xf86Msg(X_ERROR, "%s: Error reading wacom device : %s\n", local->name, strerror(errno));
return;
@@ -1214,7 +1214,7 @@ void wcmReadPacket(LocalDevicePtr local)
}
}
-int xf86WcmDevChangeControl(LocalDevicePtr local, xDeviceCtl * control)
+int wcmDevChangeControl(LocalDevicePtr local, xDeviceCtl * control)
{
#ifdef DEBUG
WacomDevicePtr priv = (WacomDevicePtr)local->private;
@@ -1224,10 +1224,10 @@ int xf86WcmDevChangeControl(LocalDevicePtr local, xDeviceCtl * control)
}
/*****************************************************************************
- * xf86WcmDevControlProc --
+ * wcmDevControlProc --
****************************************************************************/
-static void xf86WcmDevControlProc(DeviceIntPtr device, PtrCtrl* ctrl)
+static void wcmDevControlProc(DeviceIntPtr device, PtrCtrl* ctrl)
{
#ifdef DEBUG
LocalDevicePtr local = (LocalDevicePtr)device->public.devicePrivate;
@@ -1239,10 +1239,10 @@ static void xf86WcmDevControlProc(DeviceIntPtr device, PtrCtrl* ctrl)
}
/*****************************************************************************
- * xf86WcmDevClose --
+ * wcmDevClose --
****************************************************************************/
-static void xf86WcmDevClose(LocalDevicePtr local)
+static void wcmDevClose(LocalDevicePtr local)
{
WacomDevicePtr priv = (WacomDevicePtr)local->private;
WacomCommonPtr common = priv->common;
@@ -1261,11 +1261,11 @@ static void xf86WcmDevClose(LocalDevicePtr local)
}
/*****************************************************************************
- * xf86WcmDevProc --
+ * wcmDevProc --
* Handle the initialization, etc. of a wacom
****************************************************************************/
-static int xf86WcmDevProc(DeviceIntPtr pWcm, int what)
+static int wcmDevProc(DeviceIntPtr pWcm, int what)
{
LocalDevicePtr local = (LocalDevicePtr)pWcm->public.devicePrivate;
WacomDevicePtr priv = (WacomDevicePtr)local->private;
@@ -1290,7 +1290,7 @@ static int xf86WcmDevProc(DeviceIntPtr pWcm, int what)
case DEVICE_INIT:
priv->wcmDevOpenCount = 0;
priv->wcmInitKeyClassCount = 0;
- if (!xf86WcmDevOpen(pWcm))
+ if (!wcmDevOpen(pWcm))
{
DBG(1, priv, "INIT FAILED\n");
return !Success;
@@ -1300,7 +1300,7 @@ static int xf86WcmDevProc(DeviceIntPtr pWcm, int what)
break;
case DEVICE_ON:
- if (!xf86WcmDevOpen(pWcm))
+ if (!wcmDevOpen(pWcm))
{
DBG(1, priv, "ON FAILED\n");
return !Success;
@@ -1315,7 +1315,7 @@ static int xf86WcmDevProc(DeviceIntPtr pWcm, int what)
if (local->fd >= 0)
{
xf86RemoveEnabledDevice(local);
- xf86WcmDevClose(local);
+ wcmDevClose(local);
}
pWcm->public.on = FALSE;
priv->wcmDevOpenCount = 0;
@@ -1332,12 +1332,12 @@ static int xf86WcmDevProc(DeviceIntPtr pWcm, int what)
}
/*****************************************************************************
- * xf86WcmDevConvert --
+ * wcmDevConvert --
* Convert X & Y valuators so core events can be generated with
* coordinates that are scaled and suitable for screen resolution.
****************************************************************************/
-static Bool xf86WcmDevConvert(LocalDevicePtr local, int first, int num,
+static Bool wcmDevConvert(LocalDevicePtr local, int first, int num,
int v0, int v1, int v2, int v3, int v4, int v5, int* x, int* y)
{
WacomDevicePtr priv = (WacomDevicePtr) local->private;
@@ -1383,13 +1383,13 @@ static Bool xf86WcmDevConvert(LocalDevicePtr local, int first, int num,
}
/*****************************************************************************
- * xf86WcmDevReverseConvert --
+ * wcmDevReverseConvert --
* Convert X and Y to valuators in relative mode where the position of
* the core pointer must be translated into device cootdinates before
* the extension and core events are generated in Xserver.
****************************************************************************/
-static Bool xf86WcmDevReverseConvert(LocalDevicePtr local, int x, int y,
+static Bool wcmDevReverseConvert(LocalDevicePtr local, int x, int y,
int* valuators)
{
WacomDevicePtr priv = (WacomDevicePtr) local->private;
diff --git a/src/xf86Wacom.h b/src/xf86Wacom.h
index 728f9d5..7b673fe 100644
--- a/src/xf86Wacom.h
+++ b/src/xf86Wacom.h
@@ -156,7 +156,7 @@ struct _WacomModule
char *wcmEventAutoDevProbe (LocalDevicePtr local);
/* common tablet initialization regime */
-int xf86WcmInitTablet(LocalDevicePtr local, const char* id, float version);
+int wcmInitTablet(LocalDevicePtr local, const char* id, float version);
/* standard packet handler */
void wcmReadPacket(LocalDevicePtr local);
@@ -165,14 +165,14 @@ void wcmReadPacket(LocalDevicePtr local);
void wcmEvent(WacomCommonPtr common, unsigned int channel, const WacomDeviceState* ds);
/* dispatches data to XInput event system */
-void xf86WcmSendEvents(LocalDevicePtr local, const WacomDeviceState* ds);
+void wcmSendEvents(LocalDevicePtr local, const WacomDeviceState* ds);
/* generic area check for xf86Wacom.c, wcmCommon.c and wcmXCommand.c */
Bool wcmPointInArea(WacomToolAreaPtr area, int x, int y);
Bool wcmAreaListOverlap(WacomToolAreaPtr area, WacomToolAreaPtr list);
/* Change pad's mode according to it core event status */
-int xf86WcmSetPadCoreMode(LocalDevicePtr local);
+int wcmSetPadCoreMode(LocalDevicePtr local);
/* calculate the proper tablet to screen mapping factor */
void wcmMappingFactor(LocalDevicePtr local);
--
1.6.6
------------------------------------------------------------------------------
The Planet: dedicated and managed hosting, cloud storage, colocation
Stay online with enterprise data centers and the best network in the business
Choose flexible plans and management services without long-term contracts
Personal 24x7 support from experience hosting pros just a phone call away.
http://p.sf.net/sfu/theplanet-com
_______________________________________________
Linuxwacom-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/linuxwacom-devel