RFR: 8296387: [Tooltip, CSS] -fx-show-delay is only applied to the first tooltip that is shown before it is displayed [v10]

Andy Goryachev angorya at openjdk.org
Fri Jul 12 20:10:03 UTC 2024


On Wed, 10 Jul 2024 15:15:33 GMT, Kevin Rushforth <kcr at openjdk.org> wrote:

>> tests/system/src/test/java/test/robot/javafx/scene/TooltipTest.java line 233:
>> 
>>> 231:                     window.getX() + scene.getX() + button.getLayoutX() + button.getLayoutBounds().getWidth() / 2,
>>> 232:                     window.getY() + scene.getY() + button.getLayoutY() + button.getLayoutBounds().getHeight() / 2);
>>> 233:             tooltipStartTime = System.currentTimeMillis();
>> 
>> it is better to use `System.nanoTime()` instead of `currentTimeMillis()` for this kind of measurements because it is not affected by the updates to the current time (such as time sync).
>> 
>> (since there are plenty of other places where we use `currentTimeMillis()` it's probably ok - very unlikely for the test to hit this scenario)
>
> That seems like a good overall test cleanup that could be done in a follow-up issue.

created https://bugs.openjdk.org/browse/JDK-8336333

-------------

PR Review Comment: https://git.openjdk.org/jfx/pull/1394#discussion_r1676413143


More information about the openjfx-dev mailing list