src/share/classes/java/awt/EventQueue.java

Print this page

        

@@ -1091,10 +1091,17 @@
         try {
             if (edt == dispatchThread) {
                 dispatchThread = null;
             }
             AWTAutoShutdown.getInstance().notifyThreadFree(edt);
+            /*
+             * Event was posted after EDT events pumping had stopped, so start 
+             * another EDT to handle this event
+             */
+            if (peekEvent() != null) {
+                initDispatchThread();
+            }
         } finally {
             pushPopLock.unlock();
         }
     }