Signed-off-by: Chase Douglas <chase.doug...@canonical.com> Reviewed-by: Peter Hutterer <peter.hutte...@who-t.net> --- src/eventcomm.c | 4 ++-- src/synaptics.c | 2 +- src/synapticsstr.h | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/src/eventcomm.c b/src/eventcomm.c index a414827..11fa3d4 100644 --- a/src/eventcomm.c +++ b/src/eventcomm.c @@ -815,7 +815,7 @@ event_query_touch(InputInfoPtr pInfo) int rc; uint8_t prop; - priv->num_touches = 0; + priv->max_touches = 0; priv->num_mt_axes = 0; SYSCALL(rc = ioctl(pInfo->fd, EVIOCGPROP(sizeof(prop)), &prop)); @@ -873,7 +873,7 @@ event_query_touch(InputInfoPtr pInfo) }; if (mtdev->caps.slot.maximum > 0) - priv->num_touches = mtdev->caps.slot.maximum - + priv->max_touches = mtdev->caps.slot.maximum - mtdev->caps.slot.minimum + 1; priv->touch_axes = malloc(priv->num_mt_axes * diff --git a/src/synaptics.c b/src/synaptics.c index f7d21ea..8adaff4 100644 --- a/src/synaptics.c +++ b/src/synaptics.c @@ -1149,7 +1149,7 @@ DeviceInit(DeviceIntPtr dev) if (priv->has_touch) { /* x/y + whatever other MT axes we found */ - if (!InitTouchClassDeviceStruct(dev, priv->num_touches, + if (!InitTouchClassDeviceStruct(dev, priv->max_touches, XIDependentTouch, 2 + priv->num_mt_axes)) { xf86IDrvMsg(pInfo, X_ERROR, diff --git a/src/synapticsstr.h b/src/synapticsstr.h index 9a11816..a903269 100644 --- a/src/synapticsstr.h +++ b/src/synapticsstr.h @@ -278,7 +278,7 @@ typedef struct _SynapticsPrivateRec #ifdef HAVE_MULTITOUCH Bool has_touch; /* Device has multitouch capabilities */ - int num_touches; /* Number of touches supported */ + int max_touches; /* Number of touches supported */ int num_mt_axes; /* Number of multitouch axes other than X, Y */ SynapticsTouchAxisRec *touch_axes; /* Touch axis information other than X, Y */ #endif -- 1.7.8.3 _______________________________________________ xorg-devel@lists.x.org: X.Org development Archives: http://lists.x.org/archives/xorg-devel Info: http://lists.x.org/mailman/listinfo/xorg-devel