Package docking.menu

# Class NonToolbarMultiStateAction<T>

java.lang.Object
docking.action.DockingAction
docking.menu.MultiStateDockingAction<T>
docking.menu.NonToolbarMultiStateAction<T>

Type Parameters:
  `T` - the type

All Implemented Interfaces:
  `DockingActionIf`, `HelpDescriptor`

public abstract class NonToolbarMultiStateAction<T> extends MultiStateDockingAction<T>
A class for clients that wish to create a button that has multiple states, controlled by a drop-down menu. Further, this action is not meant to be added to a toolbar. If you wish for this action to appear in the toolbar, then extend `MultiStateDockingAction` instead.

To use this class, extend it, overriding the `MultiStateDockingAction.actionStateChanged(ActionState, EventTrigger)` callback. Call `DockingAction.createButton()` and add the return value to your UI.

See Also:
  - `MultiStateDockingAction`

- ## Field Summary

  ### Fields inherited from interface docking.action.DockingActionIf

  `DESCRIPTION_PROPERTY, ENABLEMENT_PROPERTY, GLOBALCONTEXT_PROPERTY, KEYBINDING_DATA_PROPERTY, MENUBAR_DATA_PROPERTY, POPUP_MENU_DATA_PROPERTY, TOOLBAR_DATA_PROPERTY`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `NonToolbarMultiStateAction(String name, String owner)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `protected void`
  `actionPerformed()`
  This method is called when the user clicks the button when this action is used as a custom button provider and not installed into the default `DockingAction` framework.
  `JButton`
  `doCreateButton()`

  ### Methods inherited from class docking.menu.MultiStateDockingAction

  `actionPerformed, actionStateChanged, addActionState, doSetCurrentActionState, getAllActionStates, getCurrentState, getCurrentUserData, getStateActions, getStates, getToolTipText, isStateEnabled, setActionStates, setCurrentActionState, setCurrentActionStateByUserData, setCurrentActionStateWithTrigger, setDefaultIcon, setGroup, setMenuBarData, setPopupMenuData, setSubGroup, setUseCheckboxForIcons, showPopup, superSetMenuBarData`

  ### Methods inherited from class docking.action.DockingAction

  `addPropertyChangeListener, addToWindowWhen, createButton, createMenuItem, dispose, doCreateMenuItem, enabledWhen, firePropertyChanged, getContextClass, getDefaultKeyBindingData, getDescription, getFullName, getHelpInfo, getHelpLocation, getHelpObject, getInceptionFromTheFirstClassThatIsNotUsOrABuilder, getInceptionInformation, getKeyBinding, getKeyBindingData, getKeyBindingType, getMenuBarData, getName, getOwner, getPopupMenuData, getPreferredKeyBindingType, getToolBarData, isAddToPopup, isEnabled, isEnabledForContext, isValidContext, markHelpUnnecessary, popupWhen, removePropertyChangeListener, setAddToAllWindows, setContextClass, setDefaultKeyBindingData, setDescription, setEnabled, setHelpLocation, setKeyBindingData, setToolBarData, setUnvalidatedKeyBindingData, shouldAddToWindow, supportsDefaultContext, toString, validContextWhen`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

  ### Methods inherited from interface docking.action.DockingActionIf

  `createMenuComponent, getOwnerDescription`

- ## Constructor Details

  - ### NonToolbarMultiStateAction

    public NonToolbarMultiStateAction(String name, String owner)

- ## Method Details

  - ### doCreateButton

    public JButton doCreateButton()
    Overrides:
      `doCreateButton` in class `MultiStateDockingAction<T>`

  - ### actionPerformed

    protected void actionPerformed()
    This method is called when the user clicks the button when this action is used as a custom button provider and not installed into the default `DockingAction` framework. This is the callback to be overridden when the child wishes to respond to user button presses that are on the button and not the drop-down. The default behavior is to show the popup menu when the button is clicked.