[PATCH xf86-input-synaptics 2/2] Do not perform a tap action when more than three touches

Chase Douglas chase.douglas at canonical.com
Fri Mar 23 10:51:59 PDT 2012


Though this looks like a behavior change, it really isn't since the
maximum tap_max_fingers that was previously possible was already handled.
The only real change is that if a tap is recognized but the
tap_max_fingers is zero, a tap will no longer be emitted. This shouldn't
happen in the real world.

Signed-off-by: Chase Douglas <chase.douglas at canonical.com>
---
In Unity we have a four tap gesture to show/hide the dash. Without this
fix, the dash will often appear and disappear because Unity got the four
tap gesture and then synaptics sends a button click.

 src/synaptics.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/src/synaptics.c b/src/synaptics.c
index f07fd13..99b5085 100644
--- a/src/synaptics.c
+++ b/src/synaptics.c
@@ -1798,7 +1798,6 @@ SelectTapButton(SynapticsPrivate *priv, edge_type edge)
 
     switch (priv->tap_max_fingers) {
     case 1:
-    default:
 	switch (edge) {
 	case RIGHT_TOP_EDGE:
 	    DBG(7, "right top edge\n");
@@ -1830,6 +1829,9 @@ SelectTapButton(SynapticsPrivate *priv, edge_type edge)
 	DBG(7, "three finger tap\n");
 	tap = F3_TAP;
 	break;
+    default:
+        priv->tap_button = 0;
+        return;
     }
 
     priv->tap_button = priv->synpara.tap_action[tap];
-- 
1.7.9.1



More information about the xorg-devel mailing list