org.jdesktop.appframework.swingx
Class SingleXFrameApplication

java.lang.Object
  extended by org.jdesktop.application.AbstractBean
      extended by org.jdesktop.application.Application
          extended by org.jdesktop.application.SingleFrameApplication
              extended by org.jdesktop.appframework.swingx.SingleXFrameApplication
Direct Known Subclasses:
MainApp

public abstract class SingleXFrameApplication
extends org.jdesktop.application.SingleFrameApplication


Nested Class Summary
 
Nested classes/interfaces inherited from class org.jdesktop.application.Application
org.jdesktop.application.Application.ExitListener
 
Constructor Summary
SingleXFrameApplication()
           
 
Method Summary
protected  org.jdesktop.swingx.JXFrame createXMainFrame()
           
protected  void deleteSessionState()
          Deletes the session state by deleting the file.
protected  void initialize(String[] args)
          

Overridden to force a JXFrame as main frame and inject SwingX specific session properties.

protected  void injectSessionProperties()
          Registers SwingX specific Properties for session storage.
 void prepareDialog(JDialog c, boolean visible)
           
protected  void prepareWindow(Window root)
          Prepares the given window.
 void show(JFrame c)
           
protected  void shutdown()
          Save session state for the component hierarchy rooted by the mainFrame.
protected  void startup()
           
 
Methods inherited from class org.jdesktop.application.SingleFrameApplication
configureWindow, getMainFrame, getMainView, setMainFrame, show, show, show
 
Methods inherited from class org.jdesktop.application.Application
addExitListener, exit, exit, getContext, getExitListeners, getInstance, getInstance, hide, launch, quit, ready, removeExitListener
 
Methods inherited from class org.jdesktop.application.AbstractBean
addPropertyChangeListener, addPropertyChangeListener, firePropertyChange, firePropertyChange, getPropertyChangeListeners, removePropertyChangeListener, removePropertyChangeListener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SingleXFrameApplication

public SingleXFrameApplication()
Method Detail

initialize

protected void initialize(String[] args)

Overridden to force a JXFrame as main frame and inject SwingX specific session properties.

Overrides:
initialize in class org.jdesktop.application.Application

prepareDialog

public void prepareDialog(JDialog c,
                          boolean visible)

startup

protected void startup()
Specified by:
startup in class org.jdesktop.application.Application

prepareWindow

protected void prepareWindow(Window root)
Prepares the given window. Injects properties from app context. Restores session state if appropriate. Registers listeners to try and track session state.

Parameters:
root -

shutdown

protected void shutdown()
Save session state for the component hierarchy rooted by the mainFrame. SingleFrameApplication subclasses that override shutdown need to remember call super.shutdown().

Overrides:
shutdown in class org.jdesktop.application.SingleFrameApplication

show

public void show(JFrame c)
Overrides:
show in class org.jdesktop.application.SingleFrameApplication

deleteSessionState

protected void deleteSessionState()
Deletes the session state by deleting the file. Useful during development when restoring to old state is not always the desired behaviour. Pending: this is incomplete, deletes the mainframe state only.


createXMainFrame

protected org.jdesktop.swingx.JXFrame createXMainFrame()

injectSessionProperties

protected void injectSessionProperties()
Registers SwingX specific Properties for session storage.