summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Hutterer <peter.hutterer@who-t.net>2010-04-29 15:03:55 +1000
committerPeter Hutterer <peter.hutterer@who-t.net>2010-04-29 15:03:55 +1000
commit776ec0ed42616769ed834b5822df3b2b0d5c0e85 (patch)
tree761a686ca3055a7365069f79a4d86bb3db5cc579
parent87b29e6004a9a7f744eb6e9c2bf9539579ecefbf (diff)
Disable ClickFinger for touchpads with more than one physical button (#26079)
If a touchpad has more than just one (or no) button, don't enable any ClickFinger settings other than button 1. The old default of enabling those clickfingers can be confusing on devices that have left and right buttons but no middle. In that case, leaving three fingers on the touchpad and clicking will result in a button 2 press (usually paste). But leaving one or two fingers on the touchpad while clicking will simply send button 1 events. This can appear like spurious button 2 events to the user. X.Org Bug 26079 <http://bugs.freedesktop.org/show_bug.cgi?id=26079> Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
-rw-r--r--src/synaptics.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/synaptics.c b/src/synaptics.c
index 091dbe1..2f432ce 100644
--- a/src/synaptics.c
+++ b/src/synaptics.c
@@ -437,11 +437,11 @@ static void set_default_parameters(LocalDevicePtr local)
tapButton2 = priv->has_left ? 0 : 3;
tapButton3 = priv->has_left ? 0 : 2;
- /* Enable multifinger-click if we don't have right/middle button,
+ /* Enable multifinger-click if only have one physical button,
otherwise clickFinger is always button 1. */
clickFinger1 = 1;
- clickFinger2 = priv->has_right ? 1 : 3;
- clickFinger3 = priv->has_middle ? 1 : 2;
+ clickFinger2 = (priv->has_right || priv->has_middle) ? 1 : 3;
+ clickFinger3 = (priv->has_right || priv->has_middle) ? 1 : 2;
/* Enable vert edge scroll if we can't detect doubletap */
vertEdgeScroll = priv->has_double ? FALSE : TRUE;