Merge lp://qastaging/~andreas-pokorny/mir/0.20-fix-1550050 into lp://qastaging/mir/0.20
Status: | Merged | ||||
---|---|---|---|---|---|
Merged at revision: | 3331 | ||||
Proposed branch: | lp://qastaging/~andreas-pokorny/mir/0.20-fix-1550050 | ||||
Merge into: | lp://qastaging/mir/0.20 | ||||
Diff against target: |
423 lines (+219/-53) 6 files modified
include/test/mir/test/doubles/mock_input_device_hub.h (+43/-0) src/server/input/default_configuration.cpp (+37/-24) src/server/input/default_input_device_hub.cpp (+14/-8) src/server/input/key_repeat_dispatcher.cpp (+41/-0) src/server/input/key_repeat_dispatcher.h (+7/-4) tests/unit-tests/input/test_key_repeat_dispatcher.cpp (+77/-17) |
||||
To merge this branch: | bzr merge lp://qastaging/~andreas-pokorny/mir/0.20-fix-1550050 | ||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Mir CI Bot | continuous-integration | Needs Fixing | |
Kevin DuBois (community) | Approve | ||
Review via email:
|
Commit message
Fixes the potential endless repeat on unplugged devices
The key repeat dispatcher now reacts on the removal of input devices by resetting potentially still active repeat alarms. The integration here is a bit clumsy, since the input device hub needs the input dispatcher to forward device events. While the input dispatcher needs it to register at the input device hub as an observer.
Description of the change
This is the small version of the fix. It makes the KeyRepeatDispatcher observe the input devices attached and resets the repeat handling alarms on device removal.
The changes in src/server/
The effect of the branch is sometimes hidden by the fact that some bluetooth drivers keep track for input states and release keys when unplugging the device. The problem is easier to reproduce with USB devices.