[PATCH xf86-input-synaptics 06/10] Rename num_touches to max_touches

Chase Douglas chase.douglas at canonical.com
Wed Feb 8 18:35:15 PST 2012


Signed-off-by: Chase Douglas <chase.douglas at canonical.com>
---
 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 3455a71..c0398fb 100644
--- a/src/synaptics.c
+++ b/src/synaptics.c
@@ -1152,7 +1152,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



More information about the xorg-devel mailing list