[PATCH synaptics v5 10/18] Disable middle mouse button emulation on clickpads
Peter Hutterer
peter.hutterer at who-t.net
Mon Mar 12 23:37:37 PDT 2012
Because, well, really, how?
Signed-off-by: Peter Hutterer <peter.hutterer at who-t.net>
---
src/synaptics.c | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
diff --git a/src/synaptics.c b/src/synaptics.c
index 77afbcd..c2e3943 100644
--- a/src/synaptics.c
+++ b/src/synaptics.c
@@ -454,6 +454,7 @@ static void set_default_parameters(InputInfoPtr pInfo)
int vertResolution = 1;
int width, height, diag, range;
int horizHyst, vertHyst;
+ int middle_button_timeout;
/* read the parameters */
if (priv->synshm)
@@ -554,7 +555,9 @@ static void set_default_parameters(InputInfoPtr pInfo)
pars->click_time = xf86SetIntOption(opts, "ClickTime", 100);
pars->clickpad = xf86SetIntOption(opts, "ClickPad", pars->clickpad); /* Probed */
pars->fast_taps = xf86SetBoolOption(opts, "FastTaps", FALSE);
- pars->emulate_mid_button_time = xf86SetIntOption(opts, "EmulateMidButtonTime", 75);
+ /* middle mouse button emulation on a clickpad? nah, you're joking */
+ middle_button_timeout = pars->clickpad ? 0 : 75;
+ pars->emulate_mid_button_time = xf86SetIntOption(opts, "EmulateMidButtonTime", middle_button_timeout);
pars->emulate_twofinger_z = xf86SetIntOption(opts, "EmulateTwoFingerMinZ", emulateTwoFingerMinZ);
pars->emulate_twofinger_w = xf86SetIntOption(opts, "EmulateTwoFingerMinW", emulateTwoFingerMinW);
pars->scroll_dist_vert = xf86SetIntOption(opts, "VertScrollDelta", vertScrollDelta);
--
1.7.7.6
More information about the xorg-devel
mailing list