mirror of
https://gitlab.freedesktop.org/libinput/libinput.git
synced 2025-12-25 22:10:05 +01:00
read-only mirror of https://gitlab.freedesktop.org/libinput/libinput
We use 2 mechanisms to unregister the trackpoint event listener depending on device removal order. 1) We have a device_removed callback, if the trackpoint gets removed before the touchpad, this gets called, sees the device being removed is the trackpoint and unregisters the listener 2) If the touchpad gets removed first, then in tp_destroy we unregister the listener 2) May be delayed beyond the destruction of the trackpoint itself if the libinput user has a reference to the libinput_device for the touchpad. When this happens the trackpoint still has an eventlistener at destroy time and an assert triggers. To fix this we must do 2) at the same time as we do 1), so at remove time. While working on this I noticed that the touchpad code was also cancelling timers at destroy time rather then remove time, which means that they may expire between remove and destroy time, and cause events to be emitted from a removed device, so this commit moves the cancelling of the timers to the remove callback as well. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net> |
||
|---|---|---|
| doc | ||
| include/linux | ||
| m4 | ||
| src | ||
| test | ||
| tools | ||
| .gitignore | ||
| autogen.sh | ||
| configure.ac | ||
| COPYING | ||
| Makefile.am | ||
| README | ||
libinput libinput is a library that handles input devices for display servers and other applications that need to directly deal with input devices. It provides device detection, device handling, input device event processing and abstraction so minimize the amount of custom input code the user of libinput need to provide the common set of functionality that users expect. Input event processing includes scaling touch coordinates, generating pointer events from touchpads, pointer acceleration, etc. libinput originates from weston, the Wayland reference compositor. The source code of libinput can be found at: http://cgit.freedesktop.org/wayland/libinput For more information, visit: http://www.freedesktop.org/wiki/Software/libinput/ Bugs can be filed in the libinput component of Wayland: https://bugs.freedesktop.org/enter_bug.cgi?product=Wayland Online API documentation: http://wayland.freedesktop.org/libinput/doc/latest/modules.html