8058136: Test api/java_awt/SplashScreen/index.html\#ClosedSplashScreenTests fails because of java.lang.IllegalStateException was not thrown

Reviewed-by: azvegint, anthony
This commit is contained in:
Sergey Bylokhov 2014-09-15 17:29:43 +04:00
parent f00468aa40
commit ca1f5068b3

View File

@ -293,6 +293,7 @@ public final class SplashScreen {
*/
public Graphics2D createGraphics() throws IllegalStateException {
synchronized (SplashScreen.class) {
checkVisible();
if (image==null) {
// get unscaled splash image size
Dimension dim = _getBounds(splashPtr).getSize();
@ -419,4 +420,4 @@ public final class SplashScreen {
private native static boolean _setImageData(long SplashPtr, byte[] data);
private native static float _getScaleFactor(long SplashPtr);
};
}