Skip to content
Commit 5ed20a77 authored by Jackal Guo's avatar Jackal Guo
Browse files

Don't cancel injected event when mouse event arrives

Currently, MotionEventInjector would cancel any injected gesture when
any MotionEvent arrives. For user using an external device to control
the pointer movement, it's almost impossible to perform the gestures.
Any slightly unintended movement results in the cancellation of the
gesture.

However, if MotionEventInjector keeps sending mouse movement events
when gesture is performing, dispatch logic would be confused and it
causes the gesture malfunction. Therefore, ignore movement events
from mouse when there is an ongoing gesture since click event from
mouse should be intended.

Bug: 116459737
Test: add a new test case in MotionEventInjectorTest
Test: a11y CTS & unit tests
Change-Id: I2c2be8cf565ba15d1a9cd6bc8c45b695c1309b56
Merged-In: I2c2be8cf565ba15d1a9cd6bc8c45b695c1309b56
parent 1fbf66bb
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment