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

Commit 1b7a14d7 authored by nergi's avatar nergi
Browse files

Add @TestApi to fetch mouse cursor position on a specific display

As part of connected display testing, test mouse with getCursorPosition
is required. This is needed for few reasons:
1. Initial cursor position
- For device with builtin pointing devices, cursor might have moved
somewhere before test started.
- Previous tests with cursor might not reset the cursor back to
default-display center on teardown (e.g. a11y tests)

2. Syncing cursor position when crossing display
While all movements are in PX, display topology-related calculations are
done in DP. The offset calculation in PointerChoreographer has multiple
pxToDp & dpToPx calculation that will have 1-2px floating-rounding
errors. It's best to avoid this rounding errors by syncing the position
after cursor crossing display.

Bug: 409180058
Test: atest CtsInputTestCases
Flag: EXEMPT test API update
Change-Id: Id20341e58f0bb3e15773113bfabb9144a1b5dc17
parent d68ce5d0
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