Commit graph

2822 commits

Author SHA1 Message Date
Peter Hutterer
edd83fe99e test: mkdir -p the udev rules and hwdb directories
Especially /run/udev/rules.d may not exist, causing a test suite failure.

https://bugs.freedesktop.org/show_bug.cgi?id=103527

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit d332a64df8)
2017-11-14 14:29:09 +10:00
Peter Hutterer
e7be909838 doc: update test suite page for ninja and other recent changes
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit b15b66616e)
2017-11-14 14:29:07 +10:00
Peter Hutterer
03cd377e00 test: fix the device name for the magic mouse test device
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit 04c6439449)
2017-11-14 14:29:01 +10:00
Peter Hutterer
89660005a8 doc: quote all paths in the doxygen file
https://bugs.freedesktop.org/show_bug.cgi?id=103532

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit fb467dce8f)
2017-11-14 14:28:57 +10:00
Peter Hutterer
5b862de70d circle.yml: add ninja dist to tests
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit e182489ce7)
2017-11-14 14:28:55 +10:00
Peter Hutterer
a83085e4f9 touchpad: allow for multiple paired keyboards
needed for the razer blade keybard which provides multiple event nodes for
one physical device but it's hard/impossible to identify which one is the real
event node we care about.

https://bugs.freedesktop.org/show_bug.cgi?id=103156

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit 4d7592066a)
2017-11-14 14:28:29 +10:00
Peter Hutterer
021865232d libinput 1.9.1
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-10-30 14:58:05 +10:00
Peter Hutterer
41a70bbe92 fallback: fix lid switch event listener being initialized twice
Once the lid is closed, the keyboard event listener is set up to open the lid
for us on keyboard events. With the right sequence, we can trigger the
listener to be added to the list multiple times, triggering an assert in the
list test code (or an infinite loop in the 1.8 branch).

Conditions:
* SW_LID value 1 - sets up the keyboard listener
* keyboard event - sets lid_is_closed to false
* SW_LID value 0 - is ignored because we're already open
* SW_LID value 1 - sets up the keyboard listener again

https://bugs.freedesktop.org/show_bug.cgi?id=103298

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-10-27 15:20:35 +10:00
Benjamin Tissoires
57c5a409d6 udev: drop the version field in device groups
The version field is a per device information. We have
no guarantees a touchscreen and a tablet device will share
the same version of the firmware (especially if both
firmwares are from different vendors).

Fixes the touch arbitration for the Dell Canvas 27

Signed-off-by: Benjamin Tissoires <benjamin.tissoires@gmail.com>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-10-26 18:25:54 +10:00
Peter Hutterer
8edae4feb6 meson: require GTK 3.20
For GDK_SEAT_CAPABILITY_ALL_POINTING

https://bugs.freedesktop.org/show_bug.cgi?id=103462

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-10-26 16:47:28 +10:00
Peter Hutterer
940658e1b7 tablet: print what capability is missing when rejecting a device
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-10-26 11:01:29 +10:00
Peter Hutterer
ed52002c8d touchpad: cap the edge palm detection zones at 8mm
The main purpose of the edge zone is to detect palms in the area where we
cannot assume a full finger size and thus cannot use any other palm detection
mechanism. 8mm should be large enough that a finger should be detected based
on other properties (size, pressure, ...).

https://bugs.freedesktop.org/show_bug.cgi?id=103330

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-10-25 14:21:44 +10:00
Peter Hutterer
d27c464a49 Revert "touchpad: cap the edge palm detection zones at 8mm"
This patch only adjusted the left edge, not the right edge which was still on
8%

This reverts commit 3e9e0e2eb1.
2017-10-25 14:21:24 +10:00
Peter Hutterer
3e9e0e2eb1 touchpad: cap the edge palm detection zones at 8mm
The main purpose of the edge zone is to detect palms in the area where we
cannot assume a full finger size and thus cannot use any other palm detection
mechanism. 8mm should be large enough that a finger should be detected based
on other properties (size, pressure, ...).

https://bugs.freedesktop.org/show_bug.cgi?id=103330

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Daniel Martin <consume.noise@gmail.com>
2017-10-24 08:28:32 +10:00
Peter Hutterer
017d6bb903 test: add a wacom bamboo test device
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-10-20 15:44:32 +10:00
Peter Hutterer
8494668c2d test: fix missing BTN_9 for the MobileStudio device
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-10-20 15:44:32 +10:00
Peter Hutterer
48a2eeb525 test: fix pid for the 13HDT pad 2017-10-20 15:44:32 +10:00
Peter Hutterer
327321a446 libinput 1.9.0
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-10-19 13:40:15 +10:00
Peter Hutterer
f061027dbb touchpad: cut down on excessive logging for palm size
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-10-19 13:28:42 +10:00
Peter Hutterer
28ef7456d3 util: add an extra assert for list_insert()
If we're adding an element that's not null or not a freshly initialized list,
chances are we haven't removed it from a previous list.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Jonas Ådahl <jadahl@gmail.com>
2017-10-18 16:17:22 +10:00
Peter Hutterer
a06256d1c3 test: unref the litest device *after* removing it from the path interface
Our own reference may be the last one that's still alive if the context is
currently suspended (litest_suspend()). If we unref before removing it from
the path interface, we access already freed memory.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Jonas Ådahl <jadahl@gmail.com>
2017-10-17 16:55:27 +10:00
Peter Hutterer
b18f9e6944 test: fix a comment in the log_priority test
We don't rely that the lid switch doesn't work in this test, but we always
print a few things when a device gets successfully added.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-10-10 19:09:29 +10:00
Peter Hutterer
a251cec994 libinput 1.8.902
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-10-10 12:15:35 +10:00
Peter Hutterer
4bb5ce5b74 Fix meson options default values
The keyword is 'value', not 'default'. With meson 0.43 this now stops
building.

https://bugs.freedesktop.org/show_bug.cgi?id=103162

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-10-10 08:21:10 +10:00
Peter Hutterer
b9914ec279 tools: restore default permissions for a source file
This was accidentally made 755 as part of e9fc59efc8

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-10-10 08:05:40 +10:00
Peter Hutterer
4f062c8c0d evdev: fix a coverity warning
'rc' is possibly unused

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-10-10 08:05:28 +10:00
Peter Hutterer
7e72c8e5bb test: always init the log_handler count and reset it last
When running with -j 1 and CK_FORK=no, the log_handler_count is shared between
the tests. The log_priority tests can invoke the log handler during
libinput_unref(), so on the next day the log handler starts with a nonzero log
handler.

Fix this by always initializing it to 0 in the tests we expect it to be zero
and resetting it last.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-10-06 10:52:57 +10:00
Peter Hutterer
3b0f1d767a doc: add a section for tablet mode switches
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-09-29 08:13:44 +10:00
Peter Hutterer
35e411a2c6 doc: add another item to the FAQ
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-09-29 08:13:00 +10:00
Peter Hutterer
1acfaa9018 doc: update the GNOME stack graph
These days it's mutter that controls the input devices, not g-s-d.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-09-28 08:43:38 +10:00
Peter Hutterer
2064a8a121 libinput 1.8.901
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-09-27 13:55:07 +10:00
Peter Hutterer
916e8296f6 test: if we're not root, return with status 77
exit code 77 signals "skip this test"

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-09-27 13:50:11 +10:00
Peter Hutterer
84d49ee49c fallback: suspend internal keyboards and trackpoints on tablet-mode switch
Because on some devices the keyboard is where the fingers are holding the
device when in tablet mode.

https://bugs.freedesktop.org/show_bug.cgi?id=102729

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-09-25 15:34:45 +10:00
Peter Hutterer
350ce2b3f1 fallback: add 'interface' to the fallback interface's method names
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-09-25 15:33:41 +10:00
Peter Hutterer
fb787e7a7e touchpad: invert an if condition to allow for early return
if (foo) {
	    everything
	}

changed to :

	if (!foo)
	    return
	everything

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-09-25 15:33:41 +10:00
Peter Hutterer
6b99fabfe8 fallback: move the fallback code into a separate file
Split out the fallback-specific device handling from the more generic
evdev-specific handling (which is supposed to be available for all devices).

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-09-25 15:33:41 +10:00
Peter Hutterer
4a1a044735 evdev: rename evdev_key_type to just key_type
This is a fallback-specific private enum, don't pretend it's evdev-related

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-09-25 15:13:37 +10:00
Peter Hutterer
27eff1ac03 evdev: abstract the get_switch_state method
Shove it into the generic dispatch interface so we don't entangle evdev and
fallback.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-09-25 15:13:37 +10:00
Peter Hutterer
6c7dd36398 Use named initializers for the various dispatch interfaces
Better for self-documentation than comments and makes it more obvious if we
initialize something wrongly.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-09-25 15:13:37 +10:00
Peter Hutterer
4c531f7e99 evdev: change prefix on some fallback-only methods
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-09-25 15:13:37 +10:00
Peter Hutterer
ea115e3c2f Merge branch 'wip/litest-use-sections-for-tests-v2' 2017-09-25 14:35:46 +10:00
Peter Hutterer
23a611ea1e fallback: allow for multiple keyboards to toggle the lid switch
Previously we only listened for events on the first one to come up, based on
the assumption that there can only be one internal keyboard. The Razer Blade
laptop keyboards come with with multiple event nodes, all looking like a
normal keyboard. The one that comes up first is one for special keys, so
typing on the internal keyboard after a lid switch does not toggle the write
state.

Fix this by allowing for up to 3 keyboard listeners for a lid switch.

https://bugs.freedesktop.org/show_bug.cgi?id=102039

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-09-25 14:14:20 +10:00
Peter Hutterer
2ad669eec5 test: fix test listing
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-09-21 15:56:52 +10:00
Peter Hutterer
76e138f512 test: fix no-device test name handling
All these tests were stored with "no device" as test name.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-09-21 15:56:50 +10:00
Peter Hutterer
ad5df72d57 test: fix test listing
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-09-21 15:56:29 +10:00
Peter Hutterer
8c2ed7adbf test: fix no-device test name handling
All these tests were stored with "no device" as test name.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-09-21 15:55:18 +10:00
Peter Hutterer
2346801b0e test: switch to a TEST_DEVICE macro for all the litest test devices
The test device initialization code was a bit of duplicated boilerplate and
required adding a reference to the devices to the 'devices' list in litest.c.
Automate this with a new TEST_DEVICE macro that adds the devices to a custom
section in the binary, then loops throught that section to get the device out.

This reduces the boilerplate for each test device to just the TEST_MACRO and
the LITEST_foo device enum entry. It also now automates the shortname of the
device.

The device's shortname was standardised in this approach as well, lowercase
and dashes only.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-09-21 15:06:17 +10:00
Peter Hutterer
5516e9ea74 test: add missing newline to an error message
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-09-21 13:39:46 +10:00
Peter Hutterer
fdd89fffea test: drop obsolete semi-mt allocation for the atmel hover device
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-09-21 13:39:46 +10:00
Peter Hutterer
4c4d400bcb test: fix the 'all codes' keyboard device
The ...create() method returned the wrong device, so this one was never
actually used. Once we start using, we get test case failures related to the
device having BTN_foo events as well. For now, just disable those codes so we
have a keyboard with all keys and pass the tests. The rest needs better
fixing.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-09-21 13:39:46 +10:00