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

Skip to content
Commit 9f26fc39 authored by Siarhei Vishniakou's avatar Siarhei Vishniakou
Browse files

Check whether pointer has stopped at liftoff - try 2

This reverts commit 21fcc2b1.

Reason for revert: fixed faulty test logic that the original CL exposed

Copying the commit message from the previous attempt:

Android uses ACTION_UP and ACTION_POINTER_UP events to signal that a
pointer has left the screen.

These events don't carry new information, and should always have the
same coordinates as the last ACTION_MOVE event.
However, these events do have a new timestamp.

Before this CL: these events are getting ignored completely by
VelocityTracker. If there's a large delay before ACTION_UP, the velocity
is still reported to be the same as the if there's no delay.

In this CL: we will check these events for timestamps. If too much time
has passed, we will clear the strategy.

Example logs:
VelocityTracker: VelocityTracker: stopped for 2970.0 ms, clearing state upon pointer liftoff.

Bug: 200900433
Change-Id: I588b616cab3afcc57f2c380ec55596cfef70a40c
Test: atest libinput_tests
Test: atest android.widget.cts.NumberPickerTest
parent 21fcc2b1
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