Module is.codion.swing.common.ui
Interface ModifiedIndicator
- All Known Implementing Classes:
SwapColorsModifiedIndicator,UnderlineModifiedIndicator
public interface ModifiedIndicator
Provides a modified indicator for a component.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final PropertyValue<String> Specifies theModifiedIndicatorto use -
Method Summary
Modifier and TypeMethodDescriptionvoidenable(JComponent component, ObservableState modified) Enables the modified indicator for the given component, based on the given modified statestatic Optional<ModifiedIndicator> instance()Returns an instance from theServiceLoader, of the type specified byINDICATOR_CLASSstatic Optional<ModifiedIndicator> Returns an instance from theServiceLoader, of the type specified byfactoryClassName
-
Field Details
-
INDICATOR_CLASS
Specifies theModifiedIndicatorto useBy default
UnderlineModifiedIndicator.- See Also:
-
-
Method Details
-
enable
Enables the modified indicator for the given component, based on the given modified state- Parameters:
component- the componentmodified- the modified state observer
-
instance
Returns an instance from theServiceLoader, of the type specified byINDICATOR_CLASS- Returns:
- an instance from the
ServiceLoaderor an emptyOptionalin case one is not found
-
instance
Returns an instance from theServiceLoader, of the type specified byfactoryClassName- Returns:
- an instance from the
ServiceLoaderor an emptyOptionalin case one is not found
-