Class MDMenuAction

All Implemented Interfaces:
com.nomagic.actions.ShortcutsNotCustomizable, ActionListener, Serializable, Cloneable, Comparable, EventListener, Action, MenuListener, PopupMenuListener

@OpenApiAll public class MDMenuAction extends MenuAction implements com.nomagic.actions.ShortcutsNotCustomizable
This class represents special kind of action. It can behave as normal actions category, but has methods which informs action about menu selecting or deselecting.
See Also:
  • Constructor Details

    • MDMenuAction

      public MDMenuAction(@CheckForNull String id, String name, @CheckForNull KeyStroke stroke, @CheckForNull String group)
      Constructs the action with given id, name, keystroke and group.
      Parameters:
      id - the id of the action.
      name - the name of the action.
      stroke - the key stroke of the action
      group - the name of the related commands group.
    • MDMenuAction

      public MDMenuAction(@CheckForNull String id, String name, int mnemonic, String group)
      Constructs the action with given id, name, mnemonic key and group.
      Parameters:
      id - the id of the action.
      name - the name of the action.
      mnemonic - the mnemonic key of the action
      group - the name of the related commands group.
  • Method Details

    • updateState

      public void updateState()
      If action has assigned relative group, takes enable flag value from this group and sets to itself.
      Overrides:
      updateState in class NMAction