The right way to do a configuration window

Posting here since I don’t know whre to post it otherwise.

What I need to achieve is a configuration window that will pop-up before the game main window when the game is started to so some resolution configuration/splash screen/this type of thing.

The problem is that I seem to not be able to avoid the AWT event pump. The problem is that when the user clicks the play button, the game starts up but the input sometimes freeze up for some seconds and there’s always a general drop of performance.
I’m using the technique used for splash screens: before they’ll disposed, they’ll spawn another thread that will run the main window.

Snippets time:

This is the Thread I use to spawn the game main window while disposing the preliminary splash screen/config window:


final Runnable closerRunner = new Runnable(){
        public void run() {
            //the main game window.
            MainWnd mw;
            mw = new MainWnd();
            mw.show();
            //this one starts the main game 
            //loops and quit only when the user 
            //quits the game
            mw.startLogic();
            mw.setVisible(false);
            mw.dispose();
        }
    };

This is the code I use in the actionPerformed event of the play button:


Thread closerThread = new Thread(closerRunner, "Closer");
        closerThread.start();
        //This will hide the config window
        //& dispose it
        setVisible(false);
        dispose();

In what I’m wrong (because I must be wrong?).