Class BasicAction

    • Field Summary

      • Fields inherited from class javax.swing.AbstractAction

        changeSupport, enabled
      • 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
    • Constructor Summary

      Constructors 
      Constructor Description
      BasicAction​(java.lang.String name, java.lang.String shortdesc)  
      BasicAction​(java.lang.String name, javax.swing.Icon icon, java.lang.String shortdesc)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.awt.Component getEventWindow​(java.awt.event.ActionEvent evt)
      Returns the window from which this action was invoked.
      • Methods inherited from class javax.swing.AbstractAction

        addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
      • Methods inherited from class java.lang.Object

        equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface javax.swing.Action

        accept
      • Methods inherited from interface java.awt.event.ActionListener

        actionPerformed
    • Constructor Detail

      • BasicAction

        public BasicAction​(java.lang.String name,
                           java.lang.String shortdesc)
      • BasicAction

        public BasicAction​(java.lang.String name,
                           javax.swing.Icon icon,
                           java.lang.String shortdesc)
    • Method Detail

      • getEventWindow

        public java.awt.Component getEventWindow​(java.awt.event.ActionEvent evt)
        Returns the window from which this action was invoked. This is currently the Frame in which the event originated.
        Parameters:
        evt - event to check the window for
        Returns:
        window in which evt originated if it can be determined - may be null