[mutter] input-settings: treat a serial of 1 as serial of 0
- From: Carlos Garnacho <carlosg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter] input-settings: treat a serial of 1 as serial of 0
- Date: Mon, 17 Dec 2018 20:35:00 +0000 (UTC)
commit 9f3d321bf22335bf679c4d2640b4ea46da096d00
Author: Peter Hutterer <peter hutterer who-t net>
Date: Mon Dec 17 15:22:44 2018 +1000
input-settings: treat a serial of 1 as serial of 0
The Wacom Xorg driver assigns a serial number of 1 for any pad that doesn't
have a serial. libinput assigns 0. Just treat 1 as 0 here, there are no pens
with a real serial 1 anyway.
Fixes https://gitlab.gnome.org/GNOME/mutter/issues/414
src/backends/meta-input-settings.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
---
diff --git a/src/backends/meta-input-settings.c b/src/backends/meta-input-settings.c
index 365577ec0..1d989f397 100644
--- a/src/backends/meta-input-settings.c
+++ b/src/backends/meta-input-settings.c
@@ -1326,7 +1326,9 @@ lookup_tool_settings (ClutterInputDeviceTool *tool,
serial = clutter_input_device_tool_get_serial (tool);
- if (serial == 0)
+ /* The Wacom driver uses serial 1 for serial-less devices but 1 is not a
+ * real serial, so let's custom-case this */
+ if (serial == 0 || serial == 1)
{
path = g_strdup_printf ("/org/gnome/desktop/peripherals/stylus/default-%s:%s/",
clutter_input_device_get_vendor_id (device),
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]