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

Commit 929da90d authored by Vania Desmonda's avatar Vania Desmonda
Browse files

Fix hover icon when drag resizing a freeform window with a stylus.

getXCursorPosition() returns NaN when using a stylus. Using getX()
returns the X coordinate for pointer index 0 regardless of the pointer
identifier.

Test: manual test with a stylus and a mouse and resize a freeform window
Flag: EXEMPT minor bug fix
Fixes: 336268312
Change-Id: I3f413f7fc93876fd02340ae56a1c5c28f3d2dc4c
parent 21629035
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
@@ -468,8 +468,7 @@ class DragResizeInputListener implements AutoCloseable {
                case MotionEvent.ACTION_HOVER_ENTER:
                case MotionEvent.ACTION_HOVER_MOVE: {
                    updateCursorType(e.getDisplayId(), e.getDeviceId(),
                            e.getPointerId(/*pointerIndex=*/0), e.getXCursorPosition(),
                            e.getYCursorPosition());
                            e.getPointerId(/*pointerIndex=*/0), e.getX(), e.getY());
                    result = true;
                    break;
                }