Peter Hutterer [Mon, 30 May 2016 05:18:32 +0000 (15:18 +1000)]
udev: mark the Logitech M570 as trackball
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Mon, 30 May 2016 05:15:50 +0000 (15:15 +1000)]
tools: add missing space in libinput-list-devices output
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Fri, 27 May 2016 00:11:52 +0000 (10:11 +1000)]
doc: grammar fix in the Makefile
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Fri, 27 May 2016 00:35:34 +0000 (10:35 +1000)]
doc: add the missing svg files to the Makefile.am
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Fri, 27 May 2016 00:33:24 +0000 (10:33 +1000)]
doc: sort the svg files alphabetically
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Wed, 25 May 2016 22:40:17 +0000 (08:40 +1000)]
pad: ignore EV_MSC events
The Wacom Express Key Remote sends the serial number via EV_MSC. At some later
point we'll need the serial to match the LEDs correctly but for now we can
ignore them.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Fri, 20 May 2016 04:59:45 +0000 (14:59 +1000)]
tools: print the pad capabilities
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Tue, 24 May 2016 01:47:48 +0000 (11:47 +1000)]
doc: update ref/unref behavior for the tablet tool
Brings it in line with the rest of libinput.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Tue, 24 May 2016 01:33:50 +0000 (11:33 +1000)]
doc: update doc to explicitly state that the seat isn't referenced
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Mon, 23 May 2016 04:33:51 +0000 (14:33 +1000)]
Drop the ALPS_RUSHMORE tag
Was only used for the touchpad hysteresis, we can re-use the wobbly touchpad
tag for this.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Thu, 19 May 2016 04:40:33 +0000 (14:40 +1000)]
udev: mark ALPS touchpads fw version 300 as wobbly touchpads
Includes the Dell Lattitude E5420 but since all alps touchpads with the same
fw version are the same (as far as we know) hooking this off the firmware
version should cover this generation.
https://bugzilla.redhat.com/show_bug.cgi?id=1336084
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Thu, 19 May 2016 05:04:24 +0000 (15:04 +1000)]
udev: add the Yoga 2 to the wobbly touchpads
https://bugs.freedesktop.org/show_bug.cgi?id=95290
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Wed, 18 May 2016 01:52:12 +0000 (11:52 +1000)]
test: skip manually setting uinput resolution if it's already set
If we have libevdev 1.5 or later, the resolution is already set, no need to
change it again. Let's rely on libevdev to do the right thing and simply skip
the rest if we have one correct nonzero resolution already set on the device.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Thu, 19 May 2016 06:03:20 +0000 (16:03 +1000)]
doc: fix a few typos
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Wed, 18 May 2016 02:41:32 +0000 (12:41 +1000)]
test: fix a couple of touchpad tests that triggered the cursor jump warning
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Wed, 18 May 2016 02:19:30 +0000 (12:19 +1000)]
touchpad: disable cursor jump detection for Wacom tablets
We haven't seen jumps on Wacom tablets yet and they cause error messages in
most of the tests. litest uses a scaling approach for most events, so a finger
move that moves from 30% to 80% of the touchpad with can easily trigger a jump
on a Wacom tablet due to its physical size.
Rather than having to fix up all tests for the larger size (and potentially
cover some other bugs) simply disable this test for Wacom tablets.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Tue, 17 May 2016 21:35:36 +0000 (07:35 +1000)]
touchpad: only use negative pressure change check on Lenovo *50 and *60 series
This was introduced for bug 94379 - an X1 Carbon 3rd. Other touchpads have
different pressure change ranges, causing this condition to trigger
randomly and resulting in a jerky pointer motion.
For now, reduce the check to the *50 and *60 series touchpads until we have
data for more touchpads that we can add one-by-one.
https://bugs.freedesktop.org/show_bug.cgi?id=95393
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Tue, 10 May 2016 02:07:36 +0000 (12:07 +1000)]
evdev: the range between dpad and trigger-happy are keys, not buttons
Affected keys:
KEY_ALS_TOGGLE
KEY_BUTTONCONFIG
KEY_TASKMANAGER
KEY_JOURNAL
KEY_CONTROLPANEL
KEY_APPSELECT
KEY_SCREENSAVER
KEY_VOICECOMMAND
KEY_BRIGHTNESS_MIN
KEY_BRIGHTNESS_MAX
KEY_KBDINPUTASSIST_PREV
KEY_KBDINPUTASSIST_NEXT
KEY_KBDINPUTASSIST_PREVGROUP
KEY_KBDINPUTASSIST_NEXTGROUP
KEY_KBDINPUTASSIST_ACCEPT
KEY_KBDINPUTASSIST_CANCEL
https://bugs.freedesktop.org/show_bug.cgi?id=95295
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Tue, 10 May 2016 02:22:40 +0000 (12:22 +1000)]
test: add a keyboard test device with all codes enabled
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Mon, 16 May 2016 01:33:38 +0000 (11:33 +1000)]
Add configure.ac check for static_assert
Part of C11, defined via assert.h.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Jonas Ådahl <jadahl@gmail.com>
Tested-by: Baruch Siach <baruch@tkos.co.il>
Peter Hutterer [Sun, 15 May 2016 23:22:15 +0000 (09:22 +1000)]
Merge branch 'wip/trackball-rotation'
Peter Hutterer [Tue, 3 May 2016 03:52:53 +0000 (13:52 +1000)]
Add support for relative device rotation (trackball only)
Trackballs are effectively stationary devices and can be positioned at any
rotation. They are also employed by users with impaired dexterity which
sometimes implies that they are positioned at an non-default angle to make the
buttons easier to reach.
Add a config option for rotation for trackball devices. Currently only
supported for 90-degree angles, if there is a need we can add more angles
later.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Thu, 12 May 2016 23:46:50 +0000 (09:46 +1000)]
gestures: don't send swipe gestures when gestures are disabled
Introduced in 6ad303b as part of an code flow optimization, causing any 3+
finger gesture to be posted as swipe gesture, even when gestures are disabled.
However, the event is filtered in the higher levels with a bug message printed
to the log.
Don't post swipe gestures for devices where gestures are disabled.
https://bugs.freedesktop.org/show_bug.cgi?id=95314
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Tue, 10 May 2016 05:34:09 +0000 (15:34 +1000)]
configure.ac: move libunwind/addr2line test to inside the test conditions
If we're not building the tests, we don't care about libinwind/addr2line.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Tue, 10 May 2016 03:53:24 +0000 (13:53 +1000)]
configure.ac: libinput 1.3.0
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Mon, 9 May 2016 01:13:55 +0000 (11:13 +1000)]
doc: add an entry about tablets in left-handed mode
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Wed, 4 May 2016 09:15:39 +0000 (19:15 +1000)]
configure.ac: libinput 1.3rc3
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Tue, 3 May 2016 05:03:40 +0000 (15:03 +1000)]
Add tagging of trackballs
Currently unused, but oh, the possibilities...
The only thing we have to go on for trackballs at the moment is whether they
have "Trackball" in the name string. All others need to be manually tagged.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Tue, 3 May 2016 05:48:12 +0000 (15:48 +1000)]
evdev: de-duplicate the model property->model flag list
Rather than a list where the only difference is the LIBINPUT_MODEL vs
EVDEV_MODEL prefix, use a macro.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Tue, 3 May 2016 04:14:04 +0000 (14:14 +1000)]
test: add a missing empty line
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Tue, 3 May 2016 04:10:51 +0000 (14:10 +1000)]
evdev: log the applied model flags in debug mode
Makes it a lot easier to figure out if the udev properties are set up
correctly.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Tue, 3 May 2016 03:44:04 +0000 (13:44 +1000)]
Constify two matrix multiplication helpers
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Mon, 2 May 2016 23:08:25 +0000 (09:08 +1000)]
doc: add an overview of the various configuration options
It's a bit hard to find what can be configured in the wall of text that is the
doxygen output. Add a TOC of the various options so it's easy to get a quick
grasp.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Mon, 2 May 2016 22:49:12 +0000 (08:49 +1000)]
doc: add missing @ingroup tag to the accel profile enum
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Tue, 16 Sep 2014 05:13:00 +0000 (15:13 +1000)]
touchpad: detect and warn about kernel tracking pointer jumps
If a touch moves by more than 20mm within a single frame, reset the motion
history, effectively discarding the movement. This is a relatively common bug
and almost always needs a kernel fix, so add an explanatory page to the docs.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Benjamin Tissoires <benjamin.tissoires@gmail.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Wed, 27 Apr 2016 07:00:18 +0000 (17:00 +1000)]
test: use a few more events for some of the tests with large pointer movements
Don't move across the touchpad in one single event, it looks like a cursor
jump that we're trying to detect in future patches.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Benjamin Tissoires <benjamin.tissoires@gmail.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Wed, 27 Apr 2016 01:32:02 +0000 (11:32 +1000)]
Make a link to the html docs available as a #define
The "latest" documentation link is the location for the master branch,
released versions have their own directory on the server.
The micro-versions of 90 and above are used for snapshots and release
candidates, so whenever we have a micro version of >= 90 we still want to link
to the "latest" documentation. In all other cases, we link to the current
release.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Benjamin Tissoires <benjamin.tissoires@gmail.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Tue, 26 Apr 2016 00:55:37 +0000 (10:55 +1000)]
tablet: fix distance normalization range after 25a9f39
25a9f39 changed the range to [-1, 1] but that's incorrect for the distance
values. Split the normalization up into two functions and make sure our
distance range is correct.
https://bugs.freedesktop.org/show_bug.cgi?id=95074
And while we're at it, sneak in a test for pressure ranges too.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Jason Gerecke <jason.gerecke@wacom.com>
Peter Hutterer [Thu, 21 Apr 2016 05:08:23 +0000 (15:08 +1000)]
touchpad: exclude Logitech touchpads from disable-while-typing
Logitech does not sell internal touchpads, the closest ones are the TK820 and
the K400 series devices. Neither of which need DWT, the touchpad is next to
the keyboard.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Thu, 21 Apr 2016 05:56:04 +0000 (15:56 +1000)]
configure.ac: libinput 1.3rc2
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Thu, 21 Apr 2016 05:21:08 +0000 (15:21 +1000)]
Fix distcheck
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Mon, 18 Apr 2016 03:56:00 +0000 (13:56 +1000)]
configure.ac: libinput 1.3rc1
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Tue, 19 Apr 2016 01:04:26 +0000 (11:04 +1000)]
tools: draw some grids for positioning testing in the event-gui
Having a grid makes it easier to detect pointer jumps
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Mon, 18 Apr 2016 03:45:47 +0000 (13:45 +1000)]
test: drop the hand-enumerated device values
C guarantees that an enum value is previous value+1, so we might as well start
at -1000 and not have to worry about the actual values.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Mon, 18 Apr 2016 03:31:46 +0000 (13:31 +1000)]
Merge branch 'wip/tablet-pad-support'
Peter Hutterer [Mon, 18 Apr 2016 03:23:39 +0000 (13:23 +1000)]
fixup! Add the LIBINPUT_DEVICE_CAP_TABLET_PAD capability and matching interface
Peter Hutterer [Fri, 5 Feb 2016 00:57:37 +0000 (10:57 +1000)]
test: tablet pad tests
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Jason Gerecke <jason.gerecke@wacom.com>
Reviewed-by: Carlos Garnacho <carlosg@gnome.org>
Peter Hutterer [Fri, 5 Feb 2016 05:16:38 +0000 (15:16 +1000)]
pad: implement wacom pad support
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Jason Gerecke <jason.gerecke@wacom.com>
Reviewed-by: Carlos Garnacho <carlosg@gnome.org>
Peter Hutterer [Wed, 10 Feb 2016 04:13:10 +0000 (14:13 +1000)]
doc: add a graphic illustrating pad vs tool support
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Jason Gerecke <jason.gerecke@wacom.com>
Reviewed-by: Carlos Garnacho <carlosg@gnome.org>
Peter Hutterer [Thu, 21 Jan 2016 02:35:11 +0000 (12:35 +1000)]
Add the LIBINPUT_DEVICE_CAP_TABLET_PAD capability and matching interface
This interface handles the buttons on the physical tablet itself, including
the touch ring and the strip.
A notable difference to other libinput interfaces here is that we do not use
linux/input.h event codes for buttons. Instead, the buttons are merely
numbered sequentially, starting at button 1. This means:
* the API is different, instead of get_button() we have get_button_number() to
drive the point home
* there is no seat button count. pads are inherently different devices and
compositors should treat them as such. The seat button count makes sense
when you want to know how many devices have BTN_LEFT down, but it makes no
sense for buttons where all the semantics are handled by the compositor
anyway.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Jason Gerecke <jason.gerecke@wacom.com>
Reviewed-by: Carlos Garnacho <carlosg@gnome.org>
Peter Hutterer [Wed, 10 Feb 2016 02:29:55 +0000 (12:29 +1000)]
tablet: move the libwacom check for left-handed-ness into a helper function
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Jason Gerecke <jason.gerecke@wacom.com>
Reviewed-by: Carlos Garnacho <carlosg@gnome.org>
Peter Hutterer [Thu, 14 Apr 2016 05:21:50 +0000 (15:21 +1000)]
evdev: always defuzz absolute touchscreens
If a touchscreen has a fuzz value use it for motion hysteresis similar to how
we do it for a touchpad. This stops pointer wobbles as seen in
https://bugs.freedesktop.org/show_bug.cgi?id=94918
It's up to the system to override or set the kernel's fuzz value correctly,
i.e. a udev hwdb entry is required where the kernel driver does not set it.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Jonas Ådahl <jadahl@gmail.com>
Peter Hutterer [Thu, 14 Apr 2016 05:38:42 +0000 (15:38 +1000)]
evdev: use a slot variable instead of dereferencing everywhere
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Jonas Ådahl <jadahl@gmail.com>
Peter Hutterer [Thu, 14 Apr 2016 05:34:43 +0000 (15:34 +1000)]
evdev: rename slot to slot_idx
No functional changes
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Jonas Ådahl <jadahl@gmail.com>
Peter Hutterer [Wed, 13 Apr 2016 05:23:44 +0000 (15:23 +1000)]
evdev: move the hysteresis code to a more generic location
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Jonas Ådahl <jadahl@gmail.com>
Peter Hutterer [Fri, 15 Apr 2016 03:26:04 +0000 (13:26 +1000)]
test: drop slot events from the singletouch device
We don't have that bit set anyway
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Tue, 12 Apr 2016 01:07:02 +0000 (11:07 +1000)]
touchpad: add LIBINPUT_MODEL_WOBBLY_TOUCHPAD for the HP 14-ac157tu
If some elantech touchpads require a hysteresis, let's use some more generic
tag for those touchpads that require correct handling of pointer wobbles.
https://bugs.freedesktop.org/show_bug.cgi?id=94897
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Frühberger [Wed, 13 Apr 2016 06:55:28 +0000 (08:55 +0200)]
touchpad: enlarge top button area by a factor 3 instead of 1.5
When the touchpad is disabled, the top software button on the Lenovo T440
series touchpads currently enlarge by a factor of 1.5 (to 15mm). This is not
enough, a user has to rotate the wrist quite uncomfortable when using
the left mouse button.
When the touchpad itself is off anyway we can extend the size of the top
software buttons to the factor 3, i.e. 30mm.
Signed-off-by: Peter Frühberger <peter.fruehberger@gmail.com>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Thu, 14 Apr 2016 00:48:41 +0000 (10:48 +1000)]
Merge branch 'wip/trackpoint-mb-emu-scrolling'
Peter Hutterer [Mon, 11 Apr 2016 02:02:55 +0000 (12:02 +1000)]
test: add test to ensure MB emulation doesn't start while the MB is down
We already handle the case where we have MB emulation active and a middle
button is pressed because we often don't know if we have a middle button on
the device.
But the other way round makes little sense, when a physical middle button is
down emulation should not engage. Test for this.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Mon, 11 Apr 2016 00:06:36 +0000 (10:06 +1000)]
evdev: enable middle-button scrolling on middle-button emulation
https://bugs.freedesktop.org/show_bug.cgi?id=94856
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Tue, 12 Apr 2016 02:59:59 +0000 (12:59 +1000)]
evdev: split scroll button state check out
Rather than checking the physical key's state, set a flag for the button to be
down. This enables us to use non-physical buttons (middle button emulation).
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Sun, 10 Apr 2016 22:55:30 +0000 (08:55 +1000)]
evdev: if we have a quick scroll button release, skip middle button emulation
The only difference between evdev_pointer_notify_physical_button() and
evdev_pointer_notify_button() is that the former filters out middle button
emulations where applicable.
Doing so effectively disables using a button for scrolling that is also used
for middle button emulation. This is intentional, it is a niche use-case
(and prone to timer races). OTOH some devices exist that only have two buttons
on the pointing stick and require button scrolling. This use-case is given
preference.
https://bugs.freedesktop.org/show_bug.cgi?id=94856
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Tue, 12 Apr 2016 02:03:00 +0000 (12:03 +1000)]
test: add test for no scroll events before the scroll button timeout
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Wed, 13 Apr 2016 01:15:56 +0000 (11:15 +1000)]
udev: update the hwdb matches to avoid use of ( and )
libudev's util_replace_chars() replaces the () with underscores so that match
would work too but let's use ? instead to make it look like a regex.
This now activates the rules for all cyapa touchpads, before they wouldn't
have applied to any device.
https://bugs.freedesktop.org/show_bug.cgi?id=93846#c12
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Mon, 11 Apr 2016 22:36:48 +0000 (08:36 +1000)]
tablet: add a fuzz-filter to avoid spamming callers with subpixel updates
This is especially a problem for the cursor tool which can be legitimately
left on the tablet. It wobbles by a couple of device units, resulting in
continuous axis updates to the caller. Pre-filter any of these events by the
axis' fuzz value so we don't even process them.
For ABS_DISTANCE which doesn't have a fuzz we hard-code a minimum fuzz of 2.
This should eventually land in the kernel though.
https://bugs.freedesktop.org/show_bug.cgi?id=94892
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Jason Gerecke <jason.gerecke@wacom.com>
Peter Hutterer [Thu, 31 Mar 2016 23:37:18 +0000 (09:37 +1000)]
test: set the umask before msktemp to silence coverity
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Mon, 11 Apr 2016 21:56:52 +0000 (07:56 +1000)]
tools: update the doc publish tool to take a subdir
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Sun, 10 Apr 2016 21:18:07 +0000 (07:18 +1000)]
tablet: fix the airbrush slider range
Supposed to be [-1, 1] but we only generated [0, 1]
Reported-by: Carlos Garnacho <carlosg@gnome.org>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Tested-by: Carlos Garnacho <carlosg@gnome.org>
Peter Hutterer [Sun, 3 Apr 2016 21:08:30 +0000 (07:08 +1000)]
timer: print the wrong offset when we have a negative timer offset bug
Makes it easier to determine if this is a libinput bug or something triggered
by the caller waiting too long to call libinput_dispatch().
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Jonas Ådahl [Fri, 8 Apr 2016 07:51:28 +0000 (15:51 +0800)]
test-pointer: Test that the default accel profile doesn't change
Make sure that changing the accel profile doesn't affect the default
accel profile.
Signed-off-by: Jonas Ådahl <jadahl@gmail.com>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Jonas Ådahl [Fri, 8 Apr 2016 07:51:27 +0000 (15:51 +0800)]
libinput: Actually return the default accel profile
We just returned the current profile instead of the default one. Fix
that.
Signed-off-by: Jonas Ådahl <jadahl@gmail.com>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Jonas Ådahl [Fri, 8 Apr 2016 07:51:26 +0000 (15:51 +0800)]
test: Handle 32 bit msec time overflows
The libinput_*_get_time() returns a 32 bit unsigned integer, but in the
tests we compared them to a 64 bit unsigned integer. This means that
when the 32 bit integer overflowed, we'd still compare to a
non-overflowed 64 bit integer, causing the tests to fail.
This commit fixes this by always casting the millisecond 64 bit unsigned
integer to a 32 unsigned integer, triggering the same overflow.
Signed-off-by: Jonas Ådahl <jadahl@gmail.com>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Thu, 7 Apr 2016 22:16:11 +0000 (08:16 +1000)]
doc: minor fixes
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Thu, 7 Apr 2016 23:14:59 +0000 (09:14 +1000)]
test: fix printf for unexpected tablet events
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Fri, 8 Apr 2016 01:08:12 +0000 (11:08 +1000)]
tools: print the button name for tablet button events
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Thu, 7 Apr 2016 05:44:23 +0000 (15:44 +1000)]
test: reduce the default abs-max range to avoid ENOMEM
This path is hit when we set up an abs device without setting specific axis
ranges. Usually because we only care that the axis is there, not the values,
see the tests of invalid devices.
0xffff is fine as max for most axes but setting it for ABS_MT_SLOT can cause
allocation errors. Reduce to 100 because we don't care about the range anyway
and 100 is still big enough for basic tests.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Eric Engestrom [Sun, 3 Apr 2016 00:47:43 +0000 (01:47 +0100)]
Fix spelling mistakes
Signed-off-by: Eric Engestrom <eric@engestrom.ch>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Tue, 5 Apr 2016 21:32:46 +0000 (07:32 +1000)]
Merge branch 'wip/touchpad-middle-button'
Peter Hutterer [Mon, 4 Apr 2016 00:06:36 +0000 (10:06 +1000)]
touchpad: add a middle button software area
Middle button interaction is most commonly to paste and it is a single-event
interaction (button press). We provided middle button in software button mode
by emulating it with a two-finger press with L+R down at the same time. This
is also what many touchpads are spectacularly bad at, it is very common to
detect the physical button down event before the second finger registers,
resulting in left or right clicks where a middle button should be triggered.
Unless the fingers are resting on the touchpad for at least one scanout, the
success rate for middle button emulation is only at 70% or so.
This patch adds a 25%-width middle button area between the left and the right
software button, everything else stays the same. To avoid immediate breakage,
the middle button emulation remains but may be removed in the future.
The doc is updated to only refer to the middle button area now.
https://bugs.freedesktop.org/show_bug.cgi?id=94755
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Mon, 4 Apr 2016 02:17:22 +0000 (12:17 +1000)]
Merge branch 'wip/t450-jumping-cursor-fixes'
Peter Hutterer [Wed, 30 Mar 2016 01:36:59 +0000 (11:36 +1000)]
touchpad: reset the motion history on significant negative pressure changes
Resetting the motion history has the side-effect of swallowing movements, we
don't calculate deltas until we have 4 motion events. During a finger release,
we're likely to get a large pressure change between two events, resetting the
motion history prevents the cursor from jumping on release.
The value of 7 found by trial-and-error, tested on the T440 and T450 hardware.
The absolute value is highly variable but recordings show that the pressure
changes only by 1 or 2 units during normal interaction. Higher pressure
changes are during finger position changes but since those should not cause a
jump anyway, we tend to win there too.
Currently only enabled for negative pressure changes, let's see how we go with
that. This is enabled for all touchpads now, but the value may need
device-specific thresholds in the future.
https://bugs.freedesktop.org/show_bug.cgi?id=94379
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Mon, 4 Apr 2016 01:54:23 +0000 (11:54 +1000)]
Merge branch 'wip/t450-jumping-cursor-fixes'
Peter Hutterer [Wed, 30 Mar 2016 05:31:07 +0000 (15:31 +1000)]
touchpad: fix left-handed top software trackpoint buttons
The previous code would swap the top software buttons depending on the
touchpad's left-handed setting, not the trackpoint setting. Changing both
devices to left-handed resulted in a double-swap, i.e. the trackpoint was
always right-handed.
https://bugs.freedesktop.org/show_bug.cgi?id=94733
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Wed, 30 Mar 2016 01:36:59 +0000 (11:36 +1000)]
touchpad: reset the motion history on significant negative pressure changes
Resetting the motion history has the side-effect of swallowing movements, we
don't calculate deltas until we have 4 motion events. During a finger release,
we're likely to get a large pressure change between two events, resetting the
motion history prevents the cursor from jumping on release.
The value of 7 found by trial-and-error, tested on the T440 and T450 hardware.
The absolute value is highly variable but recordings show that the pressure
changes only by 1 or 2 units during normal interaction. Higher pressure
changes are during finger position changes but since those should not cause a
jump anyway, we tend to win there too.
Currently only enabled for negative pressure changes, let's see how we go with
that.
https://bugs.freedesktop.org/show_bug.cgi?id=94379
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Tue, 29 Mar 2016 23:11:27 +0000 (09:11 +1000)]
test: add a test for the T450 dropped motion events
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Tue, 29 Mar 2016 03:34:00 +0000 (13:34 +1000)]
touchpad: only post motion events if we have motion
Because our delta calculation factors in previous events on touchpads (to
reduce jitter) we may get a nonzero delta if we have an event that doesn't
actually change x or y.
Drop the t->dirty workaround introduced in a608d9d, an event that virtually
disappears can mess up our state machines.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Tue, 29 Mar 2016 01:59:41 +0000 (11:59 +1000)]
test: apply the new t450 model flag to our X1 3rd test device
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Mon, 28 Mar 2016 22:33:34 +0000 (08:33 +1000)]
Fix two doxygen groupings
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Wed, 16 Mar 2016 23:35:19 +0000 (09:35 +1000)]
touchpad: drop unused parameter
Left over from an earlier version of the t450 quirk (see
a608d9dc2c70) and
unused in the merged version.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Tue, 15 Mar 2016 00:23:42 +0000 (10:23 +1000)]
configure.ac: libinput 1.2.2
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Mon, 7 Mar 2016 06:05:25 +0000 (16:05 +1000)]
touchpad: add quirk for the T450 and T460 generation hardware
The touchpad's sensors are too far apart (or the firmware interferes), causing
in a jerky movement visible especially on slow motion. We get a bunch of
normal motion events, then only ABS_MT_PRESSURE updates without x/y updates.
After about one mm of movement x/y updates resume, with the first event
covering the distance between the last motion event. That event is usually
accelerated and thus causes a large jump. Subsequent events are sufficiently
fine-grained again.
This patch counts the number of non-motion events. Once we hit 10 in a row, we
mark the first motion update as non-dirty, effectively discarding the motion
and thus stopping the pointer jumps.
https://bugs.freedesktop.org/show_bug.cgi?id=94379
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Tested-by: Benjamin Tissoires <benjamin.tissoires@gmail.com>
Peter Hutterer [Mon, 7 Mar 2016 00:12:13 +0000 (10:12 +1000)]
tablet: reject mislabelled tablet devices
The HUION 580 has a "consumer control" event node that has an ABS_VOLUME, keys
and a REL_HWHEEL. It has the same VID/PID as the pen tablet and libwacom
labels it as ID_INPUT_TABLET. This causes a crash later when we try to init
pointer acceleration for a device that doesn't have axes.
https://bugzilla.redhat.com/show_bug.cgi?id=1314955
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Thu, 3 Mar 2016 21:50:49 +0000 (07:50 +1000)]
Assert that the interface is actually filled in.
Had this in a private bug report recently. Missing hooks for open/close just
segfault with little information to debug. Add an assert, this is definitely a
bug in the caller and we don't need to recover from that.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Wed, 2 Mar 2016 22:33:22 +0000 (08:33 +1000)]
test: add two path tests for invalid devices
One test for an actual file (so far we only tested /tmp, the directory) and
one for a kernel dev that returns a udev device and thus gets one step further
in the error handling code.
Plus, I saw test code doing this (opening /dev/uinput) and it crashed (for
other reasons), so we might as well test it.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Wed, 2 Mar 2016 01:48:59 +0000 (11:48 +1000)]
touchpad: use the udev property over a compile-time vendor ID check
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Tue, 9 Feb 2016 23:24:51 +0000 (09:24 +1000)]
tablet: sanitize button mask passing
We have a struct, use it. Better than passing arrays and array lengths around.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Fri, 26 Feb 2016 05:19:57 +0000 (15:19 +1000)]
configure.ac: libinput 1.2.1
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Wed, 24 Feb 2016 03:46:48 +0000 (13:46 +1000)]
touchpad: only trigger immediate pinch detection for three fingers
If the fingers are vertically apart by more than 20mm we used to assume a
pinch gesture immediately. This is too close together for some users during
two-finger scrolling. Since we should always bias towards scrolling, only
trigger this detection for three fingers, the rest has to go through the
movement detection.
The reason for the pinch detection here was to differentiate from 3fg swipe
gestures (
83f3dbd1), hence we're still in spirit of that patch.
https://bugs.freedesktop.org/show_bug.cgi?id=94264
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Tested-by: Jan Alexander Steffens (heftig) <jan.steffens@gmail.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Peter Hutterer [Tue, 23 Feb 2016 06:13:03 +0000 (16:13 +1000)]
configure.ac: libinput 1.2.0
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>