WaitingDialog: fix dispose
[fanfix.git] / ui / WaitingDialog.java
index 7df5a8b526314917e5ef7211715f33a13ffe9f9b..0fd4574d893aa5e5650e4adc73e83ae9efba15ae 100644 (file)
@@ -163,7 +163,6 @@ public class WaitingDialog extends JDialog {
                synchronized (waitLock) {
                        if (waitScreen) {
                                setVisible(false);
-                               dispose();
                        }
                        waitScreen = true;
                }
@@ -171,5 +170,7 @@ public class WaitingDialog extends JDialog {
                if (pg != null) {
                        pg.removeProgressListener(pgl);
                }
+
+               dispose();
        }
 }