Newer Cintiqs have an outbound of 200 tablet count outside of screen area. This causes absinfo.minimum to be 200 for some tablets instead of always 0 for all tablets. Update struct _WacomDeviceRec and _WacomCommonRec to process this change.
Signed-off-by: Ping Cheng <pi...@wacom.com> --- src/wcmUSB.c | 2 ++ src/xf86Wacom.c | 2 ++ src/xf86WacomDefs.h | 8 ++++++-- 3 files changed, 10 insertions(+), 2 deletions(-) diff --git a/src/wcmUSB.c b/src/wcmUSB.c index 1bdaf3c..2e4d39e 100644 --- a/src/wcmUSB.c +++ b/src/wcmUSB.c @@ -572,6 +572,7 @@ int usbWcmGetRanges(InputInfoPtr pInfo) if (!is_touch) { + common->wcmMinX = absinfo.minimum; common->wcmMaxX = absinfo.maximum; #if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,30) @@ -605,6 +606,7 @@ int usbWcmGetRanges(InputInfoPtr pInfo) if (!is_touch) { + common->wcmMinY = absinfo.minimum; common->wcmMaxY = absinfo.maximum; #if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,30) diff --git a/src/xf86Wacom.c b/src/xf86Wacom.c index 7b565a0..a20a129 100644 --- a/src/xf86Wacom.c +++ b/src/xf86Wacom.c @@ -111,6 +111,8 @@ wcmInitialToolSize(InputInfoPtr pInfo) } else { + priv->minX = common->wcmMinX; + priv->minY = common->wcmMinY; priv->maxX = common->wcmMaxX; priv->maxY = common->wcmMaxY; priv->resolX = common->wcmResolX; diff --git a/src/xf86WacomDefs.h b/src/xf86WacomDefs.h index 1f6f43a..9b81fe0 100644 --- a/src/xf86WacomDefs.h +++ b/src/xf86WacomDefs.h @@ -253,8 +253,10 @@ struct _WacomDeviceRec int bottomY; /* Y bottom in device coordinates */ int resolX; /* X resolution */ int resolY; /* Y resolution */ - int maxX; /* tool physical maxX in device coordinates*/ - int maxY; /* tool physical maxY in device coordinates*/ + int minX; /* tool physical minX in device coordinates */ + int minY; /* tool physical minY in device coordinates */ + int maxX; /* tool physical maxX in device coordinates */ + int maxY; /* tool physical maxY in device coordinates */ unsigned int serial; /* device serial number this device takes (if 0, any serial is ok) */ unsigned int cur_serial; /* current serial in prox */ int cur_device_id; /* current device ID in prox */ @@ -396,6 +398,8 @@ struct _WacomCommonRec int wcmHWTouchSwitchState; /* touch event disable/enabled by hardware switch */ /* These values are in tablet coordinates */ + int wcmMinX; /* tablet min X value */ + int wcmMinY; /* tablet min Y value */ int wcmMaxX; /* tablet max X value */ int wcmMaxY; /* tablet max Y value */ int wcmMaxZ; /* tablet max Z value */ -- 1.9.1 ------------------------------------------------------------------------------ Learn Graph Databases - Download FREE O'Reilly Book "Graph Databases" is the definitive new guide to graph databases and their applications. Written by three acclaimed leaders in the field, this first edition is now available. Download your free book today! http://p.sf.net/sfu/NeoTech _______________________________________________ Linuxwacom-devel mailing list Linuxwacom-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linuxwacom-devel