6990352: SplashScreen.getSplashScreen() does not return null for implicitly closed splash screen
Mark the splash screen closed when it happens implicitly Reviewed-by: art, dcherepanov
This commit is contained in:
parent
bc52d31ebd
commit
214842d862
@ -318,6 +318,12 @@ public final class SplashScreen {
|
||||
checkVisible();
|
||||
_close(splashPtr);
|
||||
image = null;
|
||||
SplashScreen.markClosed();
|
||||
}
|
||||
}
|
||||
|
||||
static void markClosed() {
|
||||
synchronized (SplashScreen.class) {
|
||||
wasClosed = true;
|
||||
theInstance = null;
|
||||
}
|
||||
|
@ -928,7 +928,10 @@ public class Window extends Container implements Accessible {
|
||||
return;
|
||||
}
|
||||
if (beforeFirstWindowShown.getAndSet(false)) {
|
||||
// We don't use SplashScreen.getSplashScreen() to avoid instantiating
|
||||
// the object if it hasn't been requested by user code explicitly
|
||||
SunToolkit.closeSplashScreen();
|
||||
SplashScreen.markClosed();
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user