summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--README1
-rw-r--r--synaptics.c7
-rw-r--r--synaptics.h3
-rw-r--r--synclient.c1
4 files changed, 9 insertions, 3 deletions
diff --git a/README b/README
index bbc93d7..89c5beb 100644
--- a/README
+++ b/README
@@ -95,6 +95,7 @@ UpDownScrolling Bool If on, the up/down buttons generate button 4/5 events.
EmulateMidButtonTime Int max time (in milliseconds) for middle button emulation.
TouchpadOff Bool If on, the Touchpad is switched off (useful
if an external mouse is connected)
+GuestMouseOff Bool switch on/off guest mouse (often a stick)
LockedDrags Bool If off, a tap and drag gesture ends when you release
the finger. If on, the gesture is active until you
tap a second time.
diff --git a/synaptics.c b/synaptics.c
index df62d1a..0f17fd9 100644
--- a/synaptics.c
+++ b/synaptics.c
@@ -319,6 +319,7 @@ SynapticsPreInit(InputDriverPtr drv, IDevPtr dev, int flags)
repeater = xf86SetStrOption(local->options, "Repeater", NULL);
pars->updown_button_scrolling = xf86SetBoolOption(local->options, "UpDownScrolling", TRUE);
pars->touchpad_off = xf86SetBoolOption(local->options, "TouchpadOff", FALSE);
+ pars->guestmouse_off = xf86SetBoolOption(local->options, "GuestMouseOff", FALSE);
pars->locked_drags = xf86SetBoolOption(local->options, "LockedDrags", FALSE);
pars->tap_action[RT_TAP] = xf86SetIntOption(local->options, "RTCornerButton", 2);
pars->tap_action[RB_TAP] = xf86SetIntOption(local->options, "RBCornerButton", 3);
@@ -1037,8 +1038,10 @@ static long ComputeDeltas(SynapticsPrivate *priv, struct SynapticsHwState *hw,
}
/* Add guest device movements */
- dx += hw->guest_dx;
- dy += hw->guest_dy;
+ if (!para->guestmouse_off) {
+ dx += hw->guest_dx;
+ dy += hw->guest_dy;
+ }
*dxP = dx;
*dyP = dy;
diff --git a/synaptics.h b/synaptics.h
index a796900..6dbab2a 100644
--- a/synaptics.h
+++ b/synaptics.h
@@ -61,7 +61,8 @@ typedef struct _SynapticsSHM
Bool edge_motion_use_always; /* If false, egde motion is used only when dragging */
Bool updown_button_scrolling; /* Up/Down-Button scrolling or middle/double-click */
- Bool touchpad_off; /* Switches the Touchpad off*/
+ Bool touchpad_off; /* Switches the touchpad off */
+ Bool guestmouse_off; /* Switches the guest mouse off */
Bool locked_drags; /* Enable locked drags */
int tap_action[MAX_TAP]; /* Button to report on tap events */
Bool circular_scrolling; /* Enable circular scrolling */
diff --git a/synclient.c b/synclient.c
index ae289b3..3eb4d8d 100644
--- a/synclient.c
+++ b/synclient.c
@@ -86,6 +86,7 @@ static struct Parameter params[] = {
DEFINE_PAR("EdgeMotionUseAlways", edge_motion_use_always, PT_BOOL, 0, 1),
DEFINE_PAR("UpDownScrolling", updown_button_scrolling, PT_BOOL, 0, 1),
DEFINE_PAR("TouchpadOff", touchpad_off, PT_BOOL, 0, 1),
+ DEFINE_PAR("GuestMouseOff", guestmouse_off, PT_BOOL, 0, 1),
DEFINE_PAR("LockedDrags", locked_drags, PT_BOOL, 0, 1),
DEFINE_PAR("RTCornerButton", tap_action[RT_TAP], PT_INT, 0, 7),
DEFINE_PAR("RBCornerButton", tap_action[RB_TAP], PT_INT, 0, 7),