<AWT Dev> [11] Review Request: 8198335 java/awt/FullScreen/UninitializedDisplayModeChangeTest/UninitializedDisplayModeChangeTest.java fails in headless mode

Sergey Bylokhov Sergey.Bylokhov at oracle.com
Tue Mar 20 18:48:29 UTC 2018


Hello.
Please review fix for jdk11.

Bug: https://bugs.openjdk.java.net/browse/JDK-8198335
Webrev can be found at: http://cr.openjdk.java.net/~serb/8198335/webrev.01

This bug cause the random failures of our headless tests. The reason is 
that we try to notify the 
GraphicsEnvironment(HeadlessGraphicsEnvironment), which does not 
implement DisplayChangedListener, about display change.

It is possible to skip this notification for headlesGE only, but I think 
that it is better to make instanceof before cast to 
DisplayChangedListener, usually we use this pattern in other places.

PS. Note that WToolkit.paletteChanged and WToolkit.displayChanged use 
different threads for notifications, I have created a bug to investigate 
this: https://bugs.openjdk.java.net/browse/JDK-8199881


-- 
Best regards, Sergey.


More information about the awt-dev mailing list