- All Superinterfaces:
Action,ActionListener,Control,EventListener
A Control for toggling a boolean value.
-
Nested Class Summary
Nested classes/interfaces inherited from interface is.codion.swing.common.ui.control.Control
Control.ActionCommand, Control.BuilderFactory, Control.Command -
Field Summary
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON -
Method Summary
Modifier and TypeMethodDescriptioncopy()Returns aToggleControlBuilderinstance, based on a copy of this control, using the same valueReturns a newToggleControlBuilderinstance, based on a copy of this control, using the given state.Returns a newToggleControlBuilderinstance, based on a copy of this control, using the given value.static ControlKey<ToggleControl> static ControlKey<ToggleControl> value()Methods inherited from interface javax.swing.Action
accept, addPropertyChangeListener, getValue, isEnabled, putValue, removePropertyChangeListenerMethods inherited from interface java.awt.event.ActionListener
actionPerformedMethods inherited from interface is.codion.swing.common.ui.control.Control
background, caption, description, enabled, font, foreground, keys, keyStroke, largeIcon, mnemonic, setEnabled, smallIcon
-
Method Details
-
value
- Returns:
- the value being toggled by this toggle control
-
copy
ToggleControlBuilder copy()Returns aToggleControlBuilderinstance, based on a copy of this control, using the same value -
copy
Returns a newToggleControlBuilderinstance, based on a copy of this control, using the given value.- Parameters:
value- the value for the resulting toggle control- Returns:
- a new builder
-
copy
Returns a newToggleControlBuilderinstance, based on a copy of this control, using the given state.- Parameters:
state- the state for the resulting toggle control- Returns:
- a new builder
-
key
- Parameters:
name- the control name- Returns:
- a new
ControlKeyfor identifying aToggleControlinstance
-
key
- Parameters:
name- the control namedefaultKeyStroke- the default keystroke- Returns:
- a new
ControlKeyfor identifying aToggleControlinstance
-