Changeset 5696 in josm for trunk/src/org/openstreetmap/josm/Main.java
- Timestamp:
- 2013-02-06T01:04:27+01:00 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/Main.java
r5670 r5696 511 511 contentPanePrivate.getActionMap().remove(action); 512 512 } 513 514 /** 515 * Replies the registered action for the given shortcut 516 * @param shortcut The shortcut to look for 517 * @return the registered action for the given shortcut 518 * @since 5696 519 */ 520 public static Action getRegisteredActionShortcut(Shortcut shortcut) { 521 KeyStroke keyStroke = shortcut.getKeyStroke(); 522 if (keyStroke == null) 523 return null; 524 Object action = contentPanePrivate.getInputMap(JComponent.WHEN_IN_FOCUSED_WINDOW).get(keyStroke); 525 if (action instanceof Action) 526 return (Action) action; 527 return null; 528 } 513 529 514 530 ///////////////////////////////////////////////////////////////////////////
Note:
See TracChangeset
for help on using the changeset viewer.