Package com.j3d.ui.theme.updator
Class ThemeUpdater
java.lang.Object
com.j3d.ui.theme.updator.ThemeUpdater
Manages the updating of UI component properties based on a theme.
It holds a collection of
Locator objects, each linking a specific
theme property (represented by J3DTheme) to a method that sets
a UI component's colour property.
When update() is called, all registered components are updated
with their respective theme colours.- Author:
- Lehlogonolo Poole
- See Also:
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
entries
A list ofLocatorobjects, each representing a UI component property that needs to be updated when the theme changes.
-
-
Constructor Details
-
ThemeUpdater
public ThemeUpdater()Constructs a newThemeUpdater. Initializes an empty list of entries.
-
-
Method Details
-
remove
Removes a collection ofLocatorobjects from the updater. -
remove
Removes a singleLocatorobject from the updater.- Parameters:
l- TheLocatorobject to be removed.
-
add
Adds a newLocatorto the updater, linking a theme property to a consumer that sets a color property on a UI component. -
update
public void update()
-