[PATCH synaptics 02/12] Change condition the finger requirement obvious.

Peter Hutterer peter.hutterer at who-t.net
Thu May 6 21:41:54 PDT 2010


The need for a finger down is for all conditions, move it to the front of
the condition to make it more obvious.

Signed-off-by: Peter Hutterer <peter.hutterer at who-t.net>
---
 src/synaptics.c |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/src/synaptics.c b/src/synaptics.c
index 78eb03f..5780be3 100644
--- a/src/synaptics.c
+++ b/src/synaptics.c
@@ -1417,9 +1417,10 @@ HandleTapProcessing(SynapticsPrivate *priv, struct SynapticsHwState *hw,
 
     touch = finger && !priv->finger_state;
     release = !finger && priv->finger_state;
-    move = ((priv->tap_max_fingers <= ((priv->horiz_scroll_twofinger_on || priv->vert_scroll_twofinger_on)? 2 : 1)) &&
+    move = (finger &&
+	     (priv->tap_max_fingers <= ((priv->horiz_scroll_twofinger_on || priv->vert_scroll_twofinger_on)? 2 : 1)) &&
 	     ((abs(hw->x - priv->touch_on.x) >= para->tap_move) ||
-	     (abs(hw->y - priv->touch_on.y) >= para->tap_move)) && finger);
+	     (abs(hw->y - priv->touch_on.y) >= para->tap_move)));
 
     if (touch) {
 	priv->touch_on.x = hw->x;
-- 
1.6.6.1



More information about the xorg-devel mailing list