Class ActionsMenuCreator.MenuItemActionListener

  • All Implemented Interfaces:
    java.beans.PropertyChangeListener, java.util.EventListener
    Enclosing class:
    ActionsMenuCreator

    static class ActionsMenuCreator.MenuItemActionListener
    extends java.lang.Object
    implements java.beans.PropertyChangeListener
    Class which listens for actions changes and updates menu item.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private java.lang.ref.WeakReference<javax.swing.AbstractButton> component
      Component which should be updated.
      private java.lang.ref.WeakReference<java.beans.PropertyChangeListener> sup
      Support created by swing.
    • Constructor Summary

      Constructors 
      Constructor Description
      MenuItemActionListener​(java.beans.PropertyChangeListener sup, javax.swing.AbstractButton component)
      Creates listener.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void propertyChange​(java.beans.PropertyChangeEvent e)
      Listens for NMAction.ACTION_SHORTCUTS.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • sup

        private final java.lang.ref.WeakReference<java.beans.PropertyChangeListener> sup
        Support created by swing.
      • component

        private final java.lang.ref.WeakReference<javax.swing.AbstractButton> component
        Component which should be updated.
    • Constructor Detail

      • MenuItemActionListener

        MenuItemActionListener​(java.beans.PropertyChangeListener sup,
                               javax.swing.AbstractButton component)
        Creates listener.
        Parameters:
        sup - support which should handle changes if they are not handled in this class.
        component - component which should be updated.
    • Method Detail

      • propertyChange

        public void propertyChange​(java.beans.PropertyChangeEvent e)
        Listens for NMAction.ACTION_SHORTCUTS. and updates shortcuts for menu item.
        Specified by:
        propertyChange in interface java.beans.PropertyChangeListener