On Wed, Aug 31, 2011 at 5:52 PM, Peter Hutterer <peter.hutte...@who-t.net> wrote: > On Wed, Aug 31, 2011 at 10:12:10AM -0500, Chris Bagwell wrote: >> On Wed, Aug 31, 2011 at 1:21 AM, Peter Hutterer >> <peter.hutte...@who-t.net> wrote: >> > On Wed, Aug 24, 2011 at 06:57:17PM -0500, ch...@cnpbagwell.com wrote: >> >> From: Chris Bagwell <ch...@cnpbagwell.com> >> >> >> >> Added check for wcmGesture for 1 finger gestures since it couldn't make >> >> use of generic check. >> >> >> >> Skip 1 finger tap on touchscreens based on LCD feature instead of >> >> is_absolute() value. Also, since this is gesture specific validation, >> >> moved to inside function. >> >> >> >> Signed-off-by: Chris Bagwell <ch...@cnpbagwell.com> >> >> --- >> >> src/wcmTouchFilter.c | 15 ++++++++++++--- >> >> 1 files changed, 12 insertions(+), 3 deletions(-) >> >> >> >> diff --git a/src/wcmTouchFilter.c b/src/wcmTouchFilter.c >> >> index 57a62f6..65b9eda 100644 >> >> --- a/src/wcmTouchFilter.c >> >> +++ b/src/wcmTouchFilter.c >> >> @@ -171,6 +171,10 @@ static void wcmSingleFingerTap(WacomDevicePtr priv) >> >> >> >> DBG(10, priv, "\n"); >> >> >> >> + /* This gesture is only valid on touchpads. */ >> >> + if (TabletHasFeature(priv->common, WCM_LCD)) >> >> + return; >> >> + >> > >> > really? isn't tapping one of the simplest sequences that we'd want on >> > pretty >> > much any tablet? or is there some other gesture path that I'm missing >> > here? >> >> Tablet/Touchpad: yes Tablet/Touchscreen: no >> >> A touchscreen should give button press upon touch. If this logic is >> allowed to kick in then you get a double tap if user does a single >> tap. > > now I'm confused. what's the definition of a "tap" here? tip or finger press > and immediate release?
Here, and in whole of wcmTouchFilter.cc I believe, tap is used as finger press and immediate release. Its just barely cut off in diff but this function starts with this comment which probably would have helped show we don't want that left button press (or really the button release is more destructive on touchscreens): /* A single finger tap is defined as 1 finger tap that lasts less than * wcmTapTime. It results in a left button press. Full disclosure: I'm not sure this specific function can be pushed to much further as is. I can't get 1 finger double taps to work reliably with Bamboo's. Seems we need to put a delay in between button press and release or Gnome isn't to happy. That means a state machine with a timer instead of this single function... and that means its better to pull synaptics gesture logic into a library and reuse it... or wait until XInput 2.2. Chris > > Cheers, > Peter > >> Below it was using is_absolute() to prevent. The reason I moved is >> really in prep for next patch which moves touchscreen button presses >> here. It improves readability to me to remove if() from calling >> function. >> >> Chris >> >> > >> > Cheers, >> > Peter >> > >> >> if (!ds[0].proximity && dsLast[0].proximity && !ds[1].proximity) >> >> { >> >> /* Single Tap must have lasted less than wcmTapTime >> >> @@ -330,9 +334,14 @@ void wcmGestureFilter(WacomDevicePtr priv, int >> >> channel) >> >> } >> >> } >> >> ret: >> >> - if (common->wcmGestureMode == GESTURE_NONE_MODE && >> >> - !channel && !is_absolute(priv->pInfo)) >> >> - wcmSingleFingerTap(priv); >> >> + if (common->wcmGestureMode == GESTURE_NONE_MODE && !channel) >> >> + { >> >> + /* Since this is in ret block, can not rely on generic >> >> + * wcmGesture enable check from above. >> >> + */ >> >> + if (common->wcmGesture) >> >> + wcmSingleFingerTap(priv); >> >> + } >> >> } >> >> >> >> static void wcmSendScrollEvent(WacomDevicePtr priv, int dist, >> >> -- >> >> 1.7.6 >> >> >> >> >> >> ------------------------------------------------------------------------------ >> >> EMC VNX: the world's simplest storage, starting under $10K >> >> The only unified storage solution that offers unified management >> >> Up to 160% more powerful than alternatives and 25% more efficient. >> >> Guaranteed. http://p.sf.net/sfu/emc-vnx-dev2dev >> >> _______________________________________________ >> >> Linuxwacom-devel mailing list >> >> Linuxwacom-devel@lists.sourceforge.net >> >> https://lists.sourceforge.net/lists/listinfo/linuxwacom-devel >> >> >> > >> > ------------------------------------------------------------------------------ Special Offer -- Download ArcSight Logger for FREE! Finally, a world-class log management solution at an even better price-free! And you'll get a free "Love Thy Logs" t-shirt when you download Logger. Secure your free ArcSight Logger TODAY! http://p.sf.net/sfu/arcsisghtdev2dev _______________________________________________ Linuxwacom-devel mailing list Linuxwacom-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linuxwacom-devel