Author: echatellier Date: 2011-03-01 12:12:51 +0100 (Tue, 01 Mar 2011) New Revision: 3072 Url: http://chorem.org/repositories/revision/lima/3072 Log: #302 : IllegalStateException when trying to close already closed splash screen Modified: trunk/lima-swing/src/main/java/org/chorem/lima/LimaSplash.java Modified: trunk/lima-swing/src/main/java/org/chorem/lima/LimaSplash.java =================================================================== --- trunk/lima-swing/src/main/java/org/chorem/lima/LimaSplash.java 2011-02-16 22:00:47 UTC (rev 3071) +++ trunk/lima-swing/src/main/java/org/chorem/lima/LimaSplash.java 2011-03-01 11:12:51 UTC (rev 3072) @@ -112,7 +112,7 @@ * @param message message can be {@code null} */ public void updateProgression(double progress, String message) { - if (splashGraphics != null) { + if (splashGraphics != null && splash.isVisible()) { splashGraphics.setColor(Color.GRAY); splashGraphics.drawRect(65, 253, 300, 10); @@ -135,7 +135,7 @@ * Close splash screen (if needed). */ public void closeSplash() { - if (splash != null) { + if (splash != null && splash.isVisible()) { splash.close(); } }