summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorPeter Hutterer <peter.hutterer@who-t.net>2021-11-22 18:22:24 +1000
committerPeter Hutterer <peter.hutterer@who-t.net>2021-12-20 15:01:56 +1000
commitdc7fbbaf1c77a96f77b2cc7e57cb21baf1fa6d06 (patch)
tree19cbdd00a266982d2e2148f1b87d43743c243133 /test
parent5bfc1940e22026410cae7fcff12594a413a8b7db (diff)
downloadxf86-input-wacom-dc7fbbaf1c77a96f77b2cc7e57cb21baf1fa6d06.tar.gz
Add a copy of xf86ScaleAxis for our use
This is a simple helper function, easier to have this locally than rely on the X server API here. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Diffstat (limited to 'test')
-rw-r--r--test/fake-symbols.c28
1 files changed, 0 insertions, 28 deletions
diff --git a/test/fake-symbols.c b/test/fake-symbols.c
index 022b571..80acf31 100644
--- a/test/fake-symbols.c
+++ b/test/fake-symbols.c
@@ -108,34 +108,6 @@ xf86AddInputDriver(InputDriverPtr driver, pointer module, int flags)
return;
}
-_X_EXPORT int
-xf86ScaleAxis(int Cx,
- int to_max,
- int to_min,
- int from_max,
- int from_min )
-{
- int X;
- int64_t to_width = to_max - to_min;
- int64_t from_width = from_max - from_min;
-
- if (from_width) {
- X = (int)(((to_width * (Cx - from_min)) / from_width) + to_min);
- }
- else {
- X = 0;
- /*ErrorF ("Divide by Zero in xf86ScaleAxis\n");*/
- }
-
- if (X > to_max)
- X = to_max;
- if (X < to_min)
- X = to_min;
-
- return X;
-}
-
-
_X_EXPORT void
DeleteInputDeviceRequest(DeviceIntPtr pDev)
{