RFR: 8196017: java/awt/Mouse/GetMousePositionTest/GetMousePositionWithPopup.java fails [v2]
Alexander Zuev
kizune at openjdk.java.net
Fri Oct 29 09:24:29 UTC 2021
> The problem here is that due to the approximation of the coordinates when converting
> to and from screen cordinate system on screen with 125% magnification
> two things can happen:
> 1. New mouse position calculated can be 149/149 which is the same as the starting position
> and system can refuse to generate new mouse event which causes false positive of the test
> since second mouse motion listener was never called;
> 2. Even if event is generated the resulting reported coordinates can differ by 1 pixel
> in any of the directions;
>
> To solve it i moved away the target point to make sure that move event always generated and
> comparing expected and actual coordinates with approximation of +/- 1 pixel.
Alexander Zuev has updated the pull request incrementally with one additional commit since the last revision:
Protect from second mouse move image invocation.
-------------
Changes:
- all: https://git.openjdk.java.net/jdk/pull/6128/files
- new: https://git.openjdk.java.net/jdk/pull/6128/files/7a74a153..7dc23067
Webrevs:
- full: https://webrevs.openjdk.java.net/?repo=jdk&pr=6128&range=01
- incr: https://webrevs.openjdk.java.net/?repo=jdk&pr=6128&range=00-01
Stats: 4 lines in 1 file changed: 3 ins; 1 del; 0 mod
Patch: https://git.openjdk.java.net/jdk/pull/6128.diff
Fetch: git fetch https://git.openjdk.java.net/jdk pull/6128/head:pull/6128
PR: https://git.openjdk.java.net/jdk/pull/6128
More information about the client-libs-dev
mailing list