Package java.awt

Examples of java.awt.Component.removeFocusListener()


      ((JTextComponent)result).selectAll();
      result.addFocusListener(new FocusAdapter() {
        public void focusGained(FocusEvent arg0) {
          super.focusGained(arg0);
          ((JTextComponent)result).selectAll();
          result.removeFocusListener(this);
        }

        public void focusLost(FocusEvent arg0) {
          // TODO Auto-generated method stub
          super.focusLost(arg0);
View Full Code Here


      c.addFocusListener(new FocusAdapter() {
        public void focusGained(FocusEvent e) {
      if(!DockingUtility.isActive(parentDockable)) {
          parentDockable.getDockingProperties().setActive(true);
      }
      c.removeFocusListener(this);
        }
    });                        
      c.requestFocusInWindow();
        }
View Full Code Here

    private void removeScrollPane( JScrollPane p )
    {
      final Component c = p.getViewport().getView();
      c.removeMouseListener( this );
      c.removeFocusListener( this );
      if( DEBUG ) System.err.println( "removeFocus/MouseListener " + c.getClass().getName() + "(" + c.hashCode() + ")" );
    }

    public void componentAdded( ContainerEvent e )
    {
View Full Code Here

      cachedBounds = toolBar.getPreferredSize();
      cachedOrientation = toolBar.getOrientation();

      Component c = e.getChild();
      if (toolBarFocusListener != null)
        c.removeFocusListener(toolBarFocusListener);
    }
  }

  /**
   * This is the floating window that is returned when getFloatingWindow is
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.