Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 614c6be5 authored by Daniel Norman's avatar Daniel Norman
Browse files

Removes ACTION_CANCEL which caused InputDispatcher inconsistency.

This ACTION_CANCEL was used for two cases:
1. Cancelling an in-progress injected gesture if another injected
   gesture is requested.
2. Cancelling an in-progress real gesture if a new injected gesture is
   requested.

(2) was not functional because this ACTION_CANCEL had the deviceId of
the injected device, not the device used by real gestures. This bad
ACTION_CANCEL was then causing an inconsistent stream for future
injected events.
Rather than fix (2) this change removes that CANCEL case altogether; as of http://ag/21431224 CANCELing the real gesture is not necessary
because InputDispatcher already tracks deviceId and cancels
the real gesture on its own when A11y sends the injected gesture.

Bug: 384451671
Test: Manual testing; see b/384451671 #comment20
Test: atest MotionEventInjectorTest
Flag: com.android.server.accessibility.motion_event_injector_cancel_fix
Change-Id: I09aef2c853dfe86142e8b60e5b64c4560b2265a0
parent d88bfd50
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment