private void toggleVisibility(MenuItem showMenuItem) {
        // Hide/Unhide the window if the user clicked in the system tray icon or
        // selected the menu option
        if (frame.isVisible()) {
            frame.setVisible(false);
            showMenuItem.setLabel("Show");
        } else {
            frame.setVisible(true);
            frame.setState(Frame.NORMAL);
            showMenuItem.setLabel("Hide");
        }
    }
Creates a new GUI launcher instance.
@param args The command line arguments
@throws AWTException if AWT cannot be initialised
starter/src/main/java/org/jivesoftware/openfire/launcher/Launcher.java