UIManager.ActiveValue method
createValue. If the underlying desktop property changes this
will force the UIs to update all known Frames. You can invoke
invalidate to force the value to be fetched again.
| Modifier and Type | Class and Description |
|---|---|
| private static class | DesktopProperty.
As there is typically only one Toolkit, the PropertyChangeListener is handled via a WeakReference so as not to pin down the DesktopProperty. |
| Modifier and Type | Field and Description |
|---|---|
| private final Object | fallback
Fallback value in case we get null from desktop. |
| private final String | key
Key used to lookup value from desktop. |
| private DesktopProperty. | pcl
PropertyChangeListener attached to the Toolkit. |
| private static final ReferenceQueue | queue
ReferenceQueue of unreferenced WeakPCLs. |
| private static volatile boolean | |
| private Object | value
Value to return. |
| Access | Constructor and Description |
|---|---|
| public | DesktopProperty(String
Key used in looking up desktop value. key, Object Value used if desktop property is null. fallback)Creates a DesktopProperty. |
| Modifier and Type | Method and Description |
|---|---|
| protected Object | configureValue(Object value)
Configures the value as appropriate for a defaults property in the UIDefaults table. |
| public Object | createValue(UIDefaults table)
Implements javax. UIManager.LazyValue method, returns the value from the desktop or the fallback value if the desktop value is null. |
| public static void | |
| protected Object | |
| protected String | |
| protected Object | |
| public void | invalidate(LookAndFeel
the LookAndFeel this DesktopProperty was created with laf)Invalidates the current value. |
| public void | invalidate()
Invalidates the current value so that the next invocation of
|
| protected void | |
| protected void | updateUI()
Requests that all components in the GUI hierarchy be updated to reflect dynamic changes in this look&feel.; This update occurs by uninstalling and re-installing the UI objects. |
| private static void |
| fallback | back to summary |
|---|---|
| private final Object fallback Fallback value in case we get null from desktop. | |
| key | back to summary |
|---|---|
| private final String key Key used to lookup value from desktop. | |
| pcl | back to summary |
|---|---|
| private DesktopProperty. PropertyChangeListener attached to the Toolkit. | |
| queue | back to summary |
|---|---|
| private static final ReferenceQueue<DesktopProperty> queue ReferenceQueue of unreferenced WeakPCLs. | |
| updatePending | back to summary |
|---|---|
| private static volatile boolean updatePending | |
| value | back to summary |
|---|---|
| private Object value Value to return. | |
| DesktopProperty | back to summary |
|---|---|
| public DesktopProperty(String key, Object fallback) Creates a DesktopProperty. | |
| configureValue | back to summary |
|---|---|
| protected Object configureValue(Object value) Configures the value as appropriate for a defaults property in the UIDefaults table. | |
| createValue | back to summary |
|---|---|
| public Object createValue(UIDefaults table) Implements javax. UIManager.LazyValue method, returns the value from the desktop or the fallback value if the desktop value is null. | |
| flushUnreferencedProperties | back to summary |
|---|---|
| public static void flushUnreferencedProperties() Cleans up any lingering state held by unrefeernced DesktopProperties. | |
| getDefaultValue | back to summary |
|---|---|
| protected Object getDefaultValue() Returns the value to use if the desktop property is null. | |
| getKey | back to summary |
|---|---|
| protected String getKey() Returns the key used to lookup the desktop properties value. | |
| getValueFromDesktop | back to summary |
|---|---|
| protected Object getValueFromDesktop() Returns the value from the desktop. | |
| invalidate | back to summary |
|---|---|
| public void invalidate(LookAndFeel laf) Invalidates the current value.
| |
| invalidate | back to summary |
|---|---|
| public void invalidate() Invalidates the current value so that the next invocation of
| |
| updateAllUIs | back to summary |
|---|---|
| protected void updateAllUIs() Updates the UIs of all the known Frames. | |
| updateUI | back to summary |
|---|---|
| protected void updateUI() Requests that all components in the GUI hierarchy be updated to reflect dynamic changes in this look&feel. This update occurs by uninstalling and re-installing the UI objects. Requests are batched and collapsed into a single update pass because often many desktop properties will change at once. | |
| updateWindowUI | back to summary |
|---|---|
| private static void updateWindowUI(Window window) Updates the UI of the passed in window and all its children. | |
| Modifier and Type | Field and Description |
|---|---|
| private String | |
| private LookAndFeel |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| pack-priv void | |
| public void | propertyChange(PropertyChangeEvent pce)
Implements java. This method gets called when a bound property is changed. |
| WeakPCL | back to summary |
|---|---|
| pack-priv WeakPCL(DesktopProperty target, String key, LookAndFeel laf) | |
| dispose | back to summary |
|---|---|
| pack-priv void dispose() | |
| propertyChange | back to summary |
|---|---|
| public void propertyChange(PropertyChangeEvent pce) Implements java. Doc from java. This method gets called when a bound property is changed. | |