On Thu, Dec 10, 2009 at 10:35 PM, Peter Hutterer
<[email protected]>wrote:

> > diff --git a/src/wcmValidateDevice.c b/src/wcmValidateDevice.c
> > index ed02507..c33187f 100644
> > --- a/src/wcmValidateDevice.c
> > +++ b/src/wcmValidateDevice.c
> > @@ -618,6 +618,10 @@ int wcmParseOptions(LocalDevicePtr local)
> >       /* Touch applies to the whole tablet */
> >       common->wcmTouch = xf86SetBoolOption(local->options, "Touch",
> common->wcmTouchDefault);
> >
> > +     /* Touch gesture applies to the whole tablet */
> > +     common->wcmGesture = xf86SetBoolOption(local->options, "Gesture",
> > +                     common->wcmGestureDefault);
>
> need to look at the code but I noticed here we check for that option twice,
> once in wcmUSB.c, once in wcmValidateDevice. may be something to keep an
> eye
> on?
>

The check is needed for both files.  In wcmValidateDevice.c, it is to
initialize the value for all devices that are defined in xorg.conf.  Later
on in wcmUSB.c (and wcmISDV4.c as well), they are reassigned due the
possible changes in device specific features.

Let me know if this confuses you more.

Ping


diff --git a/src/wcmUSB.c b/src/wcmUSB.c
index 49cafc4..788bc88 100644
--- a/src/wcmUSB.c
+++ b/src/wcmUSB.c
@@ -550,6 +550,14 @@ Bool usbWcmInit(LocalDevicePtr local, char* id, float
*version)
              * For penabled TabletPCs. TabletPC is on by default */
             common->wcmTPCButtonDefault = 1;
         }
+
+        /* 2FG touch device */
+        if (ISBITSET (keys, BTN_TOOL_TRIPLETAP))
+        {
+            /* GestureDefault was off for all devices
+             * except when multi-touch is supported */
+            common->wcmGestureDefault = 1;
+        }
     }

     if (!common->wcmModel)
@@ -562,6 +570,10 @@ Bool usbWcmInit(LocalDevicePtr local, char* id, float
*version)
     common->wcmTouch = xf86SetBoolOption(local->options, "Touch",
         common->wcmTouchDefault);

+    /* Touch gesture applies to the whole tablet */
+    common->wcmGesture = xf86SetBoolOption(local->options, "Gesture",
+        common->wcmGestureDefault);
+
     /* check if TPCButton was turned off in xorg.conf for pen */
     if (priv->flags & STYLUS_ID)
         common->wcmTPCButton = xf86SetBoolOption(local->options,
------------------------------------------------------------------------------
Return on Information:
Google Enterprise Search pays you back
Get the facts.
http://p.sf.net/sfu/google-dev2dev
_______________________________________________
Linuxwacom-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/linuxwacom-devel

Reply via email to