File xf86-input-synaptics-fix-clickpad-capabilities.diff of Package xorg-x11-driver-input
---
src/eventcomm.c | 26 ++++++++++++++++++++------
1 file changed, 20 insertions(+), 6 deletions(-)
--- a/src/eventcomm.c
+++ b/src/eventcomm.c
@@ -169,6 +169,25 @@
}
static void
+event_query_clickpad(LocalDevicePtr local)
+{
+ SynapticsPrivate *priv = (SynapticsPrivate *)local->private;
+
+ /* clickpad device reports only the single left button mask */
+ if (priv->has_left && !priv->has_right && !priv->has_middle &&
+ !priv->has_double &&
+ priv->model == MODEL_SYNAPTICS) {
+ priv->is_clickpad = TRUE;
+ /* enable right/middle button caps; otherwise gnome-settings-daemon
+ * will ignore this device for left/right-hand setup because of a
+ * single-button
+ */
+ priv->has_right = priv->has_middle = TRUE;
+ xf86Msg(X_INFO, "%s: is Clickpad device\n", local->name);
+ }
+}
+
+static void
event_query_led(LocalDevicePtr local)
{
SynapticsPrivate *priv = (SynapticsPrivate *)local->private;
@@ -297,12 +316,6 @@
}
xf86Msg(X_PROBED, "%s: buttons:%s\n", local->name, buf);
-
- /* clickpad device reports only the single left button mask */
- if (priv->has_left && !priv->has_right && !priv->has_middle && !priv->has_double) {
- priv->is_clickpad = TRUE;
- xf86Msg(X_PROBED, "%s: is Clickpad device\n", local->name);
- }
}
}
@@ -462,6 +475,7 @@
if (event_query_is_touchpad(local->fd, (need_grab) ? *need_grab : TRUE))
event_query_axis_ranges(local);
event_query_info(local);
+ event_query_clickpad(local);
event_query_led(local);
}