@Override public void addShutdownWindow(final Window window){
  if (m_isShutDown) {
    closeWindow(window);
    return;
  }
synchronized (this) {
    if (m_isShutDown) {
      closeWindow(window);
      return;
    }
    m_windowsToCloseOnShutdown.add(window);
  }
}

@ Override public void addShutdownWindow ( final Window window ) { if ( m_isShutDown ) { closeWindow ( window ) ; return ; } synchronized ( this ) { if ( m_isShutDown ) { closeWindow ( window ) ; return ; } m_windowsToCloseOnShutdown . add ( window ) ; } }
add a latch that will be released when the game shuts down .
