configure.ac | 4 ++-- debian/changelog | 6 ++++++ doc/device-configuration-via-udev.dox | 2 +- src/evdev-mt-touchpad-buttons.c | 2 +- src/evdev-mt-touchpad-edge-scroll.c | 4 ++-- src/evdev-tablet-pad-leds.c | 4 ++++ test/test-touchpad-buttons.c | 32 ++++++++++++++++++++++++++++++++ test/test-touchpad.c | 2 +- tools/event-debug.c | 2 +- tools/libinput-list-devices.c | 9 ++++++++- 10 files changed, 58 insertions(+), 9 deletions(-)
New commits: commit 756c430bc21c44b3f73f9aebb0184a4a579ddfad Author: Timo Aaltonen <tjaal...@debian.org> Date: Fri Mar 10 14:05:10 2017 +0200 update the changelog diff --git a/debian/changelog b/debian/changelog index f2e2c5e..ec88927 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +libinput (1.6.3-1) UNRELEASED; urgency=medium + + * New upstream release. + + -- Timo Aaltonen <tjaal...@debian.org> Fri, 10 Mar 2017 13:37:01 +0200 + libinput (1.6.2-1) unstable; urgency=medium * New upstream release. commit b2325b33fc0e9b4bb1d35ba5d125c66f448b9b14 Author: Peter Hutterer <peter.hutte...@who-t.net> Date: Wed Mar 8 17:02:29 2017 +1000 configure.ac: libinput 1.6.3 Signed-off-by: Peter Hutterer <peter.hutte...@who-t.net> diff --git a/configure.ac b/configure.ac index 98877aa..1747834 100644 --- a/configure.ac +++ b/configure.ac @@ -2,7 +2,7 @@ AC_PREREQ([2.64]) m4_define([libinput_major_version], [1]) m4_define([libinput_minor_version], [6]) -m4_define([libinput_micro_version], [2]) +m4_define([libinput_micro_version], [3]) m4_define([libinput_version], [libinput_major_version.libinput_minor_version.libinput_micro_version]) @@ -35,7 +35,7 @@ AM_INIT_AUTOMAKE([1.11 foreign no-dist-gzip dist-xz]) # b) If interfaces have been changed or added, but binary compatibility has # been preserved, change to C+1:0:A+1 # c) If the interface is the same as the previous version, change to C:R+1:A -LIBINPUT_LT_VERSION=21:4:11 +LIBINPUT_LT_VERSION=21:5:11 AC_SUBST(LIBINPUT_LT_VERSION) AM_SILENT_RULES([yes]) commit 4e1610a28650f813b01cfca859e2a57ce5f20b08 Author: Peter Hutterer <peter.hutte...@who-t.net> Date: Wed Mar 1 11:26:06 2017 +1000 touchpad: ignore hovering touches for the software button state If a touch started hovering in the main area, the button state would start with AREA and never move to the real button state, despite the finger triggering the pressure thresholds correctly in one of the areas. This could even happen across touch sequences if a touch went below pressure in the software button area, it changed to hovering and the button state changed to NONE. On the next event, the touch is still hovering and the current position of the touch is taken for the button state machine. https://bugs.freedesktop.org/show_bug.cgi?id=99976 Signed-off-by: Peter Hutterer <peter.hutte...@who-t.net> Reviewed-by: Hans de Goede <hdego...@redhat.com> (cherry picked from commit c0dbd6eb38c000ebe10c25d07152bb6154bcc73e) diff --git a/src/evdev-mt-touchpad-buttons.c b/src/evdev-mt-touchpad-buttons.c index 3cd118c..b7989f4 100644 --- a/src/evdev-mt-touchpad-buttons.c +++ b/src/evdev-mt-touchpad-buttons.c @@ -458,7 +458,7 @@ tp_button_handle_state(struct tp_dispatch *tp, uint64_t time) struct tp_touch *t; tp_for_each_touch(tp, t) { - if (t->state == TOUCH_NONE) + if (t->state == TOUCH_NONE || t->state == TOUCH_HOVERING) continue; if (t->state == TOUCH_END) { diff --git a/test/test-touchpad-buttons.c b/test/test-touchpad-buttons.c index 63d02f2..cf9678a 100644 --- a/test/test-touchpad-buttons.c +++ b/test/test-touchpad-buttons.c @@ -1476,6 +1476,37 @@ START_TEST(clickpad_softbutton_right_to_left) } END_TEST +START_TEST(clickpad_softbutton_hover_into_buttons) +{ + struct litest_device *dev = litest_current_device(); + struct libinput *li = dev->libinput; + + litest_drain_events(li); + + litest_hover_start(dev, 0, 50, 50); + libinput_dispatch(li); + litest_hover_move_to(dev, 0, 50, 50, 90, 90, 10, 0); + libinput_dispatch(li); + + litest_touch_move_to(dev, 0, 90, 90, 91, 91, 1, 0); + + litest_button_click(dev, BTN_LEFT, true); + libinput_dispatch(li); + + litest_assert_button_event(li, + BTN_RIGHT, + LIBINPUT_BUTTON_STATE_PRESSED); + litest_assert_empty_queue(li); + + litest_button_click(dev, BTN_LEFT, false); + litest_touch_up(dev, 0); + + litest_assert_button_event(li, + BTN_RIGHT, + LIBINPUT_BUTTON_STATE_RELEASED); +} +END_TEST + START_TEST(clickpad_topsoftbuttons_left) { struct litest_device *dev = litest_current_device(); @@ -1961,6 +1992,7 @@ litest_setup_tests_touchpad_buttons(void) litest_add("touchpad:softbutton", clickpad_softbutton_left_2nd_fg_move, LITEST_CLICKPAD, LITEST_APPLE_CLICKPAD); litest_add("touchpad:softbutton", clickpad_softbutton_left_to_right, LITEST_CLICKPAD, LITEST_APPLE_CLICKPAD); litest_add("touchpad:softbutton", clickpad_softbutton_right_to_left, LITEST_CLICKPAD, LITEST_APPLE_CLICKPAD); + litest_add("touchpad:softbutton", clickpad_softbutton_hover_into_buttons, LITEST_CLICKPAD|LITEST_HOVER, LITEST_APPLE_CLICKPAD); litest_add("touchpad:topsoftbuttons", clickpad_topsoftbuttons_left, LITEST_TOPBUTTONPAD, LITEST_ANY); litest_add("touchpad:topsoftbuttons", clickpad_topsoftbuttons_right, LITEST_TOPBUTTONPAD, LITEST_ANY); commit 8dea77ff493b8cf730fe08dd4508444ccdb90309 Author: Peter Hutterer <peter.hutte...@who-t.net> Date: Tue Feb 28 16:44:17 2017 +1000 tools: fix printing of tablet coordinates Signed-off-by: Peter Hutterer <peter.hutte...@who-t.net> (cherry picked from commit 07ce6c895478d0da5d2d5be6712556f46f463108) diff --git a/tools/event-debug.c b/tools/event-debug.c index 2c9766c..fe5dc08 100644 --- a/tools/event-debug.c +++ b/tools/event-debug.c @@ -421,7 +421,7 @@ print_tablet_axes(struct libinput_event_tablet_tool *t) (libinput_event_tablet_tool_##ax##_has_changed(ev) ? "*" : "") x = libinput_event_tablet_tool_get_x(t); - y = libinput_event_tablet_tool_get_x(t); + y = libinput_event_tablet_tool_get_y(t); printf("\t%.2f%s/%.2f%s", x, changed_sym(t, x), y, changed_sym(t, y)); commit 2fcf482d06a8a467a98686c45a24b8cb58ef7a03 Author: Peter Hutterer <peter.hutte...@who-t.net> Date: Mon Feb 27 11:02:06 2017 +1000 touchpad: reduce minimum height for horiz edge scrolling to 40mm Introduced in commit 8e7f99c27ab39 we only allowed horizontal edge scrolling on devices larger than 50mm to leave enough reactive space on the touchpad. Looking at a ruler, a 50mm high touchpad is still large enough to leave the bottom 7mm as an horizontal edge scroll area. Reduce the minimum size to 40mm instead, that's closer to where it starts to get a bit iffy. https://bugzilla.redhat.com/show_bug.cgi?id=1422221 Signed-off-by: Peter Hutterer <peter.hutte...@who-t.net> Reviewed-by: Hans de Goede <hdego...@redhat.com> (cherry picked from commit d6379bc3f3ee57a02b23f99b82a50aaa4cfe7b04) diff --git a/src/evdev-mt-touchpad-edge-scroll.c b/src/evdev-mt-touchpad-edge-scroll.c index 1d30bca..5551a8d 100644 --- a/src/evdev-mt-touchpad-edge-scroll.c +++ b/src/evdev-mt-touchpad-edge-scroll.c @@ -291,14 +291,14 @@ tp_edge_scroll_init(struct tp_dispatch *tp, struct evdev_device *device) struct phys_coords mm = { 0.0, 0.0 }; evdev_device_get_size(device, &width, &height); - /* Touchpads smaller than 50mm are not tall enough to have a + /* Touchpads smaller than 40mm are not tall enough to have a horizontal scroll area, it takes too much space away. But clickpads have enough space here anyway because of the software button area (and all these tiny clickpads were built when software buttons were a thing, e.g. Lenovo *20 series) */ if (!tp->buttons.is_clickpad) - want_horiz_scroll = (height >= 50); + want_horiz_scroll = (height >= 40); /* 7mm edge size */ mm.x = width - 7; diff --git a/test/test-touchpad.c b/test/test-touchpad.c index 8d28e96..4d5fa05 100644 --- a/test/test-touchpad.c +++ b/test/test-touchpad.c @@ -462,7 +462,7 @@ touchpad_has_horiz_edge_scroll_size(struct litest_device *dev) rc = libinput_device_get_size(dev->libinput_device, &width, &height); - return rc == 0 && height >= 50; + return rc == 0 && height >= 40; } START_TEST(touchpad_edge_scroll_horiz) commit 3940ab7f40a39a045e888068d199871e6d669392 Author: Peter Hutterer <peter.hutte...@who-t.net> Date: Fri Feb 24 10:15:23 2017 +1000 tools: add mode group info to libinput-list-devices We don't cater for the special case of groups having a different number of modes, there is no hardware right now that does that. Signed-off-by: Peter Hutterer <peter.hutte...@who-t.net> Reviewed-by: Hans de Goede <hdego...@redhat.com> (cherry picked from commit 38c675c9599fabeb8c530ab74898524a71cacf75) diff --git a/tools/libinput-list-devices.c b/tools/libinput-list-devices.c index e202388..8fd25df 100644 --- a/tools/libinput-list-devices.c +++ b/tools/libinput-list-devices.c @@ -245,16 +245,23 @@ rotation_default(struct libinput_device *device) static void print_pad_info(struct libinput_device *device) { - int nbuttons, nrings, nstrips; + int nbuttons, nrings, nstrips, ngroups, nmodes; + struct libinput_tablet_pad_mode_group *group; nbuttons = libinput_device_tablet_pad_get_num_buttons(device); nrings = libinput_device_tablet_pad_get_num_rings(device); nstrips = libinput_device_tablet_pad_get_num_strips(device); + ngroups = libinput_device_tablet_pad_get_num_mode_groups(device); + + group = libinput_device_tablet_pad_get_mode_group(device, 0); + nmodes = libinput_tablet_pad_mode_group_get_num_modes(group); printf("Pad:\n"); printf(" Rings: %d\n", nrings); printf(" Strips: %d\n", nstrips); printf(" Buttons: %d\n", nbuttons); + printf(" Mode groups: %d (%d modes)\n", ngroups, nmodes); + } static void commit 7b11fef3490277317f4a794beeadf206a48844f6 Author: Peter Hutterer <peter.hutte...@who-t.net> Date: Fri Feb 24 10:10:44 2017 +1000 Fix a crash when requesting invalid mode group indices Signed-off-by: Peter Hutterer <peter.hutte...@who-t.net> Reviewed-by: Hans de Goede <hdego...@redhat.com> (cherry picked from commit c787ccf270f44007dbadce72c1516b819c2ca5ce) diff --git a/src/evdev-tablet-pad-leds.c b/src/evdev-tablet-pad-leds.c index 209ab73..89b3b9d 100644 --- a/src/evdev-tablet-pad-leds.c +++ b/src/evdev-tablet-pad-leds.c @@ -645,5 +645,9 @@ evdev_device_tablet_pad_get_mode_group(struct evdev_device *device, if (!(device->seat_caps & EVDEV_DEVICE_TABLET_PAD)) return NULL; + if (index >= + (unsigned int)evdev_device_tablet_pad_get_num_mode_groups(device)) + return NULL; + return pad_get_mode_group(pad, index); } commit e2fc437342523fbadc3b99e0b3a9b0d19e5a8fde Author: Peter Hutterer <peter.hutte...@who-t.net> Date: Thu Feb 23 07:04:55 2017 +1000 doc: minor documentation fix Signed-off-by: Peter Hutterer <peter.hutte...@who-t.net> (cherry picked from commit d248049f8ded9acaedb328d3b09dc89661586546) diff --git a/doc/device-configuration-via-udev.dox b/doc/device-configuration-via-udev.dox index 7987073..82a3554 100644 --- a/doc/device-configuration-via-udev.dox +++ b/doc/device-configuration-via-udev.dox @@ -108,7 +108,7 @@ ENV{ID_MODEL_ID}=="034b", ENV{ID_INPUT_TOUCHPAD}="", ENV{ID_INPUT_TABLET}="1" @section model_specific_configuration Model-specific configuration libinput reserves the property prefixes <b>LIBINPUT_MODEL_</b> and -<b>LIBINPUT_ATTR_*</b> for model-specific configuration. <b>These prefixes +<b>LIBINPUT_ATTR_</b> for model-specific configuration. <b>These prefixes are reserved as private API, do not use.</b> The effect of these properties may be to enable or disable certain