Class JXTree.CellEditorRemover

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

    public class JXTree.CellEditorRemover
    extends java.lang.Object
    implements java.beans.PropertyChangeListener
    This class tracks changes in the keyboard focus state. It is used when the JXTree is editing to determine when to terminate the edit. If focus switches to a component outside of the JXTree, but in the same window, this will terminate editing. The exact terminate behaviour is controlled by the invokeStopEditing property.
    See Also:
    JTree.setInvokesStopCellEditing(boolean)
    • Field Summary

      Fields 
      Modifier and Type Field Description
      (package private) java.awt.KeyboardFocusManager focusManager
      the focusManager this is listening to.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void propertyChange​(java.beans.PropertyChangeEvent ev)  
      void release()
      stops listening.
      private void setKeyboardFocusManager​(java.awt.KeyboardFocusManager current)
      Sets the focusManager this is listening to.
      void updateKeyboardFocusManager()
      Updates itself to listen to the current KeyboardFocusManager.
      • Methods inherited from class java.lang.Object

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

      • focusManager

        java.awt.KeyboardFocusManager focusManager
        the focusManager this is listening to.
    • Constructor Detail

      • CellEditorRemover

        public CellEditorRemover()
    • Method Detail

      • updateKeyboardFocusManager

        public void updateKeyboardFocusManager()
        Updates itself to listen to the current KeyboardFocusManager.
      • release

        public void release()
        stops listening.
      • setKeyboardFocusManager

        private void setKeyboardFocusManager​(java.awt.KeyboardFocusManager current)
        Sets the focusManager this is listening to. Unregisters/registers itself from/to the old/new manager, respectively.
        Parameters:
        current - the KeyboardFocusManager to listen too.
      • propertyChange

        public void propertyChange​(java.beans.PropertyChangeEvent ev)
        Specified by:
        propertyChange in interface java.beans.PropertyChangeListener