Commit graph

2366 commits

Author SHA1 Message Date
Peter Hutterer
ab563d0920 evdev: fix a comment typo
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-31 12:46:51 +10:00
Peter Hutterer
a5cefb76ac doc: add a table of contents to the FAQ
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-31 09:52:22 +10:00
Peter Hutterer
2f89c3fec3 Merge branch 'tablet-pad-modes-kernel' 2017-01-31 09:07:01 +10:00
Peter Hutterer
9672e2f407 test: fix two test udev rules
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-30 13:36:20 +10:00
Peter Hutterer
aae997e60e doc: update the FAQ entry with how config options are stored
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-30 10:11:21 +10:00
Peter Hutterer
6ef816b4f5 autogen.sh: exec the configure script
No point in waiting for it here, might as well pass the baton.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-26 14:43:35 +10:00
Mihail Konev
2ec596c265 autogen: add default patch prefix
Signed-off-by: Mihail Konev <k.mvc@ya.ru>
2017-01-26 14:43:10 +10:00
Peter Hutterer
b2109ca535 touchpad: use a helper function for the libinput context
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-25 17:08:51 +10:00
Peter Hutterer
13a2336beb evdev: fix an error message
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-25 13:24:48 +10:00
Peter Hutterer
a64f9df5ce Drop normalized_get_direction, use physical distances instead
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
2017-01-23 10:43:04 +10:00
Peter Hutterer
33d708e2de touchpad: convert normalized_length to physical coordinates
Now that the acceleration code doesn't use dpi-normalized coordinates anymore,
we don't need to use them in the touchpad code. Switch to physical distances
instead, it makes debugging a lot saner.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
2017-01-23 10:37:08 +10:00
Peter Hutterer
43352590f7 touchpad: mask out ABS_MT if we don't have or disable MT
Make sure the events we deal with are the ones we actually honor. This reduces
the chance that we accidentally process events we weren't event supposed to
get based on some earlier device decision.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
2017-01-23 10:00:48 +10:00
Peter Hutterer
5eb71b65e4 pad: implement kernel-based pad led handling
For each device open the various led devices (brightness only) and map the one
nonzero brightness to the current mode.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-20 14:32:35 +10:00
Peter Hutterer
ebeba8e8ff Merge branch 'wip/wheel-tilt-source' 2017-01-20 12:51:53 +10:00
Peter Hutterer
dbb376f74b test: add wheel tilt tests
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
2017-01-20 11:45:29 +10:00
Peter Hutterer
631fab6ebd Merge branch 'gcov' 2017-01-20 10:35:55 +10:00
Peter Hutterer
aba825658b test: add test to set tap map on unsupported devices
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-20 10:35:45 +10:00
Peter Hutterer
35421834c7 test: check the pad button state in litest_is_pad_button_event
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-20 10:35:45 +10:00
Peter Hutterer
7fe7f50a37 test: add tests for tablet buttons and button seat count
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-20 10:35:45 +10:00
Peter Hutterer
20b354449f test: add more tests for tap-drag config
Including one to get/set it on unsupported devices

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-20 10:35:45 +10:00
Peter Hutterer
44fe6f6312 test: ad calls to check whether pressure has changed
Nothing actually called that function, sprinkle a few calls into existing
tests to make sure it actually works.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-20 10:35:45 +10:00
Peter Hutterer
96f0140749 test: test absence of scroll events on keyboards
Executes the paths to set invalid scroll methods.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-20 10:35:45 +10:00
Peter Hutterer
989113cdb9 test: add device size/no size checks
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-20 10:35:45 +10:00
Peter Hutterer
db0f84b3ce test: add a test for the tool ID
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-20 10:35:44 +10:00
Peter Hutterer
a7f4939f91 test: add a test for tablet pad event timestamps
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-20 10:35:44 +10:00
Peter Hutterer
dbeaa06712 test: add test for tablet_tool_get/set_user_data
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-20 10:35:44 +10:00
Peter Hutterer
d9f09cec76 test: add a tablet tool capability check
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-20 10:35:44 +10:00
Peter Hutterer
4e7db651ce test: add a test to force a destroy for the path backend
The test suite (and tests) we have now all clean up nicely before calling the
final libinput_unref(). Add one where there's at least one device still
connected.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-20 10:35:44 +10:00
Peter Hutterer
b887ddc756 test: add some device capability checks
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-20 10:35:44 +10:00
Peter Hutterer
0d09791afb test: add test for fetching invalid pointer axes
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-20 10:35:44 +10:00
Peter Hutterer
a1a10242bd test: test for libinput_device_get/set_user_data
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-20 10:35:44 +10:00
Peter Hutterer
66d12ac8ff test: add tests for checking for buttons for a non-pointer device
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-20 10:35:44 +10:00
Peter Hutterer
9ab8e7f783 util: make all property parsing helpers ignore NULL strings
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-20 10:35:43 +10:00
Peter Hutterer
7c6784dd81 test: add test for invalid path operations on udev backends
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-20 10:35:43 +10:00
Peter Hutterer
0a34ed409e test: add test for invalid udev_assign_seat on path context
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-20 10:35:43 +10:00
Peter Hutterer
fcddfc6b11 test: add helper function to install a "bug expected" log handler
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-20 10:35:43 +10:00
Peter Hutterer
50dfd52cd7 test: add a test for keyboard LED updates
Not much we can check for here anyway, but at least we can trigger the code.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-20 10:35:43 +10:00
Peter Hutterer
a87e2558cf Hook up gcov for coverage reports
./configure --enable-gcov adds the required flags to link everything ready for
gcov. A new make gcov target runs the test suite, then pulls all the gcov bits
together into ./test/gcov-reports/ including a summary file.

The script to pull everything out is used in libevdev too, we just have an
extra condition here to ignore the selftest gcov bits (it overwrites the
useful litest.c coverage output).

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-20 10:35:37 +10:00
Peter Hutterer
7f78251018 configure.ac: libinput 1.6.0
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-20 08:29:28 +10:00
Peter Hutterer
5f0d310ead filter: normalize deltas before processing or returning them
When the filter code switched to raw device coordinates (bdd4264d) the input
data remained in device coordinates. Since the factor for touchpads was still
based on the physical velocity (and thus all touchpads get the same
acceleration factor for identical moves), the actual delta was dependent on
the resolution. e.g.

touchpad with 40u/mm: delta of 2/2 * accel factor 2 -> accel delta of 4/4
touchpad with 20u/mm: delta of 1/1 * accel factor 2 -> accel delta of 2/2

The normalized coordinates should be independent of the touchpad's resolution
though.

Affected by this was the standard mouse accel code and the touchpad accel
code, other filters always returned unnormalized coordinates (separate bug,
not addressed here).

This patch restores the correct behaviour for mice and touchpads
while leaving the special filters untouched. For comparision:
* 1000+dpi mice: accelerate normalized, return normalized
* touchpads: accelerate unnormalized, return normalized
* low-dpi mice: accelerate unnormalized, return unnormalized
* trackpoints: accelerate unnormalized, return unnormalized
* x230: don't touch, already does the right thing

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

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
2017-01-19 11:56:28 +10:00
Peter Hutterer
79339bca9c filter: change the tracker delta type to device-units
We were just switching type here without actual normalization, the filter code
is in device units as of bdd4264d61.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
2017-01-19 09:34:28 +10:00
Peter Hutterer
8660c19f71 gitignore: add test suite runner binary to gitignore
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-18 09:10:12 +10:00
Peter Hutterer
493a7dc0f1 Update gitignore for new test source names
Fallout from 5d66edc9f4

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-18 09:08:29 +10:00
Rohith Mukku
393a7ff5e9 Fix typos in Documentation
Signed-off-by: Rohith Mukku <rohithmukku@gmail.com>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-18 08:24:36 +10:00
Peter Hutterer
a04ba9a276 test: check if left-handed is available for the left-handed tests
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-17 07:53:49 +10:00
Peter Hutterer
1dccc4fdff test: fix some tablet tests' unreached code
These conditions were never triggered by our test suite, so let's tighten up
the tests to match what we expect.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-17 07:53:49 +10:00
Peter Hutterer
4d20130e05 test: fix pointer accel defaults test
Loop immediately exited, this code was never triggered.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-17 07:53:49 +10:00
Peter Hutterer
9483a7a2c0 test: simplify some checks in the path test
The first event is always a device added event, skip the loops that would
paper over this. If we ever change this, the tests *should* fail.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-17 07:53:49 +10:00
Peter Hutterer
a9016f7e15 test: remove some untriggered code from the keyboard tests
The second condition was never triggered because we shouldn't get anything but
keyboard events here. Drain the initial event burst and remove the two
skipping conditions that won't happen anyway.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-17 07:53:49 +10:00
Peter Hutterer
5dcb949c3d Fix doxygen references for natural scroll config
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-16 16:36:17 +10:00