|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.jgoodies.uif.util.ComponentUtils
public final class ComponentUtils
Consists only of static convenience methods around components.
Method Summary | |
---|---|
static void |
addAction(JComponent component,
Action action,
KeyStroke keyStroke)
Adds the given action to the input map of the given component for the given key stroke. |
static void |
addAction(JComponent component,
Action action,
KeyStroke keyStroke,
int condition)
Adds the given action to the input map of the given component for the given key stroke. |
static void |
addEnterAction(JComponent component,
Action action)
Adds the given action to the input map of the given component as a action on pressing the ENTER key. |
static void |
removeAction(JComponent component,
Action action,
KeyStroke keyStroke,
int condition)
Removes the given action from the input map of the given component for the given key stroke. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static void addAction(JComponent component, Action action, KeyStroke keyStroke)
component
- the component that shall hold the actionaction
- the action to addkeyStroke
- the key stroke that initiates the actionpublic static void addAction(JComponent component, Action action, KeyStroke keyStroke, int condition)
component
- the component that shall hold the actionaction
- the action to addkeyStroke
- the key stroke that initiates the actioncondition
- one of JComponent.WHEN_IN_FOCUSED_WINDOW,
WHEN_FOCUSED, WHEN_ANCESTOR_OF_FOCUSED_COMPONENTpublic static void addEnterAction(JComponent component, Action action)
component
- the component that shall hold the actionaction
- the action to addpublic static void removeAction(JComponent component, Action action, KeyStroke keyStroke, int condition)
component
- the component that shall hold the actionaction
- the action to addkeyStroke
- the key stroke that initiates the actioncondition
- one of JComponent.WHEN_IN_FOCUSED_WINDOW,
WHEN_FOCUSED, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |