@OpenApiAll public class SelectionStateItem extends NMStateAction implements ListItem, com.nomagic.actions.ShortcutsNotCustomizable
SelectItemAction
,
Serialized FormDISTINGUISH, GROUPED, STATE
ACTION_SHORTCUTS, BELONGS_TO_SEPARATE_GROUP_IN_UI, DO_NO_SHOW_ACTION_NAME_IN_UI, GENERATED_ID_PREFIX, GROUP, ID, LARGE_ICON, MENU_SHORTCUT_MASK, TINY_ICON
Constructor and Description |
---|
SelectionStateItem(java.lang.String id,
java.lang.Object value,
java.lang.String propertyName)
Creates new action.
|
Modifier and Type | Method and Description |
---|---|
void |
actionPerformed(java.awt.event.ActionEvent e)
Fires property change event with name this.propertyName and with new value this.value,
and null old value.
|
java.lang.String |
getPropertyName() |
java.lang.Object |
getValue()
Returns value of this action.
|
accept, getState, isDistinguish, isGrouped, setDistinguish, setGrouped, setState
addAction, addPropertyChangeListener, addShortcut, addShotcut, addWeakPropertyChangeListener, clone, compareTo, createMenuItem, equals, firePropertyChange, forEach, forEachIncludingSelf, getActions, getCommandKey, getDescription, getGroup, getIcon, getID, getLargeIcon, getLargeOrSmallIcon, getMenuShortcutMaskAsString, getMnemonicKey, getName, getPropertyChangeListeners, getShortcuts, getSmallIcon, getSmallOrLargeIcon, getTinyIcon, hashCode, hasMenuShortcutMask, isIDGenerated, removeAction, removeIf, removePropertyChangeListener, removeShortcut, removeWeakPropertyChangeListener, setActions, setDescription, setGroup, setIcon, setLargeIcon, setMnemonicKey, setName, setShortcuts, setSmallIcon, setTinyIcon, shallowClone, toString, updateState
getKeys, getValue, isEnabled, putValue, setEnabled
public SelectionStateItem(@CheckForNull java.lang.String id, java.lang.Object value, java.lang.String propertyName)
id
- action idvalue
- action value, action name is created from value.toString method.propertyName
- Property name of event which will be fired when this action will be executed.public void actionPerformed(java.awt.event.ActionEvent e)
actionPerformed
in interface java.awt.event.ActionListener
actionPerformed
in class NMStateAction
e
- event caused execution.public java.lang.Object getValue()
public java.lang.String getPropertyName()