cage.utility
Class OnActionFocusSwitcher

java.lang.Object
  extended by cage.utility.OnActionFocusSwitcher
All Implemented Interfaces:
java.awt.event.ActionListener, java.util.EventListener

public class OnActionFocusSwitcher
extends java.lang.Object
implements java.awt.event.ActionListener

Implementation of ActionListener that tries to focus a given component when fired.


Constructor Summary
OnActionFocusSwitcher(javax.swing.JComponent c)
          Creates a new OnActionFocusSwitcher.
OnActionFocusSwitcher(javax.swing.JComponent c, javax.swing.JComponent target)
          Creates a new OnActionFocusSwitcher and adds it to the specified JComboBox or AbstractButton.
 
Method Summary
 void actionPerformed(java.awt.event.ActionEvent e)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

OnActionFocusSwitcher

public OnActionFocusSwitcher(javax.swing.JComponent c)
Creates a new OnActionFocusSwitcher.

Parameters:
c - The component that needs to be focused.

OnActionFocusSwitcher

public OnActionFocusSwitcher(javax.swing.JComponent c,
                             javax.swing.JComponent target)
Creates a new OnActionFocusSwitcher and adds it to the specified JComboBox or AbstractButton.

Parameters:
c - The component that needs to be focused.
target - The JComboBox or AbstractButton to which needs to be listened
Method Detail

actionPerformed

public void actionPerformed(java.awt.event.ActionEvent e)
Specified by:
actionPerformed in interface java.awt.event.ActionListener