public final class InputMapUtils extends Object
Modifier | Constructor and Description |
---|---|
private |
InputMapUtils() |
Modifier and Type | Method and Description |
---|---|
static void |
addEnterAction(JComponent c,
Action a)
Add an action activated with Enter key on a component.
|
static void |
addSpacebarAction(JComponent c,
Action a)
Add an action activated with Spacebar key on a component.
|
static void |
enableEnter(JButton b)
Enable activating button on Enter (which is replaced with spacebar for certain Look-And-Feels).
|
static void |
unassignCtrlShiftUpDown(JComponent cmp,
int condition)
Unassign Ctrl-Shift/Alt-Shift Up/Down from the given component
to allow global JOSM shortcuts to work in this component.
|
static void |
unassignPageUpDown(JComponent cmp,
int condition)
Unassign PageUp/PageDown from the given component
to allow global JOSM shortcuts to work in this component.
|
private InputMapUtils()
public static void unassignCtrlShiftUpDown(JComponent cmp, int condition)
cmp
- The Swing componentcondition
- one of the following values:
public static void unassignPageUpDown(JComponent cmp, int condition)
cmp
- The Swing componentcondition
- one of the following values:
public static void enableEnter(JButton b)
b
- Buttonpublic static void addEnterAction(JComponent c, Action a)
c
- The Swing componenta
- action activated with Enter keypublic static void addSpacebarAction(JComponent c, Action a)
c
- The Swing componenta
- action activated with Spacebar key