|
qflib 0.98.0 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--de.qfs.lib.config.ConfigWrapper | +--de.qfs.lib.config.JSplitPaneConfigWrapper
A ConfigWrapper for JSplitPane
objects. The
state saved is the location of the divider.
The JSplitPaneConfigWrapper has special constructors that configure it to force an initial setting of the divider which can otherwise be difficult to achieve due to timing problems.
Field Summary | |
protected javax.swing.JSplitPane |
pane
The wrapped JSplitPane. |
protected boolean |
registered
Whether the wrapper is registered with the Configuration. |
Constructor Summary | |
JSplitPaneConfigWrapper()
Create a new JSplitPaneConfigWrapper with the default name "splitpane". |
|
JSplitPaneConfigWrapper(javax.swing.JSplitPane client,
java.lang.String name,
double defaultLocation)
Create a new JSplitPaneConfigWrapper that will enforce the initial setting of the divider location. |
|
JSplitPaneConfigWrapper(javax.swing.JSplitPane client,
java.lang.String name,
int defaultLocation)
Create a new JSplitPaneConfigWrapper that will enforce the initial setting of the divider location. |
Method Summary | |
java.util.Properties |
getConfigurableState()
Get the Configurable's state. |
void |
propertyChange(java.beans.PropertyChangeEvent e)
Notify the JSplitPaneConfigWrapper of a change in the JSplitPane. |
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 |
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 de.qfs.lib.config.ConfigWrapper |
addPackage, getConfigurableName, makeWrapper, makeWrapper, setConfigurableName |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected javax.swing.JSplitPane pane
protected boolean registered
Constructor Detail |
public JSplitPaneConfigWrapper()
public JSplitPaneConfigWrapper(javax.swing.JSplitPane client, java.lang.String name, int defaultLocation)
client
- The JSplitPane to wrap.name
- The configurable name.defaultLocation
- The default divider location for the split pane
if no state has been saved.public JSplitPaneConfigWrapper(javax.swing.JSplitPane client, java.lang.String name, double defaultLocation)
client
- The JSplitPane to wrap.name
- The configurable name.defaultLocation
- The default divider location for the split pane
if no state has been saved.Method Detail |
protected void setClient(java.lang.Object client)
setClient
in class ConfigWrapper
client
- The client object to set.public java.util.Properties getConfigurableState()
getConfigurableState
in class ConfigWrapper
de.qfs.lib.config.ConfigWrapper
public void setConfigurableState(java.util.Properties state)
setConfigurableState
in class ConfigWrapper
de.qfs.lib.config.ConfigWrapper
state
- The state to set. Ignored.public void registrationChanged(Configuration config, java.lang.String name, boolean registered, boolean valuesKept)
registrationChanged
in class ConfigWrapper
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.public void propertyChange(java.beans.PropertyChangeEvent e)
propertyChange
in interface java.beans.PropertyChangeListener
e
- The event containing the details of the change.
|
qflib 0.98.0 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |