summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Hutterer <peter.hutterer@who-t.net>2010-11-17 09:05:10 +1000
committerPeter Hutterer <peter.hutterer@who-t.net>2010-11-17 09:42:44 +1000
commit4d1e1aea077c0283808e2a1d8120a0eca85f2da7 (patch)
treef40700ee61b3cbb29f6165956c8bf67396ae37c5
parentbf5f2cf9420948415dcf6b62fa940a6de6e7b9a9 (diff)
Specify Valuator modes on initialization.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
-rw-r--r--src/xf86HyperPen.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/xf86HyperPen.c b/src/xf86HyperPen.c
index b132b65..0e722da 100644
--- a/src/xf86HyperPen.c
+++ b/src/xf86HyperPen.c
@@ -648,7 +648,8 @@ xf86HypOpenDevice(DeviceIntPtr pHyp)
priv->hypXSize, /* max val */
LPI2CPM(priv->hypRes), /* resolution */
0, /* min_res */
- LPI2CPM(priv->hypRes)); /* max_res */
+ LPI2CPM(priv->hypRes), /* max_res */
+ (priv->flags & ABSOLUTE_FLAG)? Absolute : Relative);
InitValuatorAxisStruct(pHyp,
1,
axis_labels[1],
@@ -656,7 +657,8 @@ xf86HypOpenDevice(DeviceIntPtr pHyp)
priv->hypYSize, /* max val */
LPI2CPM(priv->hypRes), /* resolution */
0, /* min_res */
- LPI2CPM(priv->hypRes)); /* max_res */
+ LPI2CPM(priv->hypRes), /* max_res */
+ (priv->flags & ABSOLUTE_FLAG)? Absolute : Relative);
InitValuatorAxisStruct(pHyp,
2,
axis_labels[2],
@@ -664,7 +666,8 @@ xf86HypOpenDevice(DeviceIntPtr pHyp)
511, /* max val */
512, /* resolution */
0, /* min_res */
- 512); /* max_res */
+ 512, /* max_res */
+ (priv->flags & ABSOLUTE_FLAG)? Absolute : Relative);
return (pInfo->fd != -1);
}