de.qfs.lib.config
Class DialogConfigWrapper
java.lang.Object
|
+--de.qfs.lib.config.ConfigWrapper
|
+--de.qfs.lib.config.DialogConfigWrapper
- All Implemented Interfaces:
- java.awt.event.ComponentListener, Configurable, java.util.EventListener
- Direct Known Subclasses:
- JDialogConfigWrapper, RelativeDialogConfigWrapper
- public class DialogConfigWrapper
- extends ConfigWrapper
- implements java.awt.event.ComponentListener
A ConfigWrapper for Dialog
objects. The state saved
is the dialog's location and size.
- Version:
- $Revision: 1.10 $
- Author:
- Gregor Schmid
Constructor Summary |
DialogConfigWrapper()
Create a new DialogConfigWrapper with the default name "dialog". |
Method Summary |
void |
componentHidden(java.awt.event.ComponentEvent e)
|
void |
componentMoved(java.awt.event.ComponentEvent e)
|
void |
componentResized(java.awt.event.ComponentEvent e)
|
void |
componentShown(java.awt.event.ComponentEvent e)
|
java.util.Properties |
getConfigurableState()
Get the Configurable's state. |
void |
registrationChanged(Configuration config,
java.lang.String name,
boolean registered,
boolean valuesKept)
This callback is used to notify the Configurable whenever it is
registered with or unregistered from the Configuration, so it can
decide whether to notify the Configuration when its state changes. |
protected void |
restore(java.awt.Dimension size,
java.awt.Point location)
|
protected void |
setClient(java.lang.Object client)
Set the client object for the ConfigWrapper. |
void |
setConfigurableState(java.util.Properties state)
Set the Configurable's state. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
dialog
protected java.awt.Dialog dialog
- The wrapped Dialog.
regHelper
protected RegistrationHelper regHelper
- Helper for registration callbacks.
DialogConfigWrapper
public DialogConfigWrapper()
- Create a new DialogConfigWrapper with the default name "dialog".
setClient
protected void setClient(java.lang.Object client)
- Set the client object for the ConfigWrapper.
- Overrides:
setClient
in class ConfigWrapper
- Parameters:
client
- The client object to set.
getConfigurableState
public java.util.Properties getConfigurableState()
- Get the Configurable's state.
- Overrides:
getConfigurableState
in class ConfigWrapper
- Following copied from class:
de.qfs.lib.config.ConfigWrapper
- Returns:
- An empty Properties object.
setConfigurableState
public void setConfigurableState(java.util.Properties state)
- Set the Configurable's state.
- Overrides:
setConfigurableState
in class ConfigWrapper
- Following copied from class:
de.qfs.lib.config.ConfigWrapper
- Parameters:
state
- The state to set. Ignored.
registrationChanged
public void registrationChanged(Configuration config,
java.lang.String name,
boolean registered,
boolean valuesKept)
- This callback is used to notify the Configurable whenever it is
registered with or unregistered from the Configuration, so it can
decide whether to notify the Configuration when its state changes.
- Overrides:
registrationChanged
in class ConfigWrapper
- Parameters:
config
- The affected Configuration.name
- The registration name of the Configurable which may
be different from the Configurable's name.registered
- True if the Configurable was just registered,
false if it was unregistered.valuesKept
- Whether the Configurable's values were kept, if
it was just unregistered.
componentMoved
public void componentMoved(java.awt.event.ComponentEvent e)
- Specified by:
componentMoved
in interface java.awt.event.ComponentListener
componentResized
public void componentResized(java.awt.event.ComponentEvent e)
- Specified by:
componentResized
in interface java.awt.event.ComponentListener
componentHidden
public void componentHidden(java.awt.event.ComponentEvent e)
- Specified by:
componentHidden
in interface java.awt.event.ComponentListener
componentShown
public void componentShown(java.awt.event.ComponentEvent e)
- Specified by:
componentShown
in interface java.awt.event.ComponentListener
restore
protected void restore(java.awt.Dimension size,
java.awt.Point location)