|
Oracle Fusion Middleware Java API Reference for Oracle Extension SDK 11g Release 2 (11.1.2.2.0) E17493-03 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object
oracle.ide.keyboard.MultiMapAdapter
public final class MultiMapAdapter
This class contains some utilities for the keyboard mapping.
Note that you need to update the MultiInputMap
when the user changes the accelerators. For example:
final KeyStrokeContextRegistry kscr = Ide.getKeyStrokeContextRegistry(); final KeyStrokeContext ksc = kscr.getContext(key); final KeyStrokeOptions kso = Ide.getSettings().getKeyStrokeOptions(); final MultiInputMap imap = MultiMapAdapter.getLocalMap(kso, ksc); kso.addChangeListener(new ChangeListener() { public void stateChanged(ChangeEvent e) { MultiMapAdapter.fillLocalMap(imap, kso, ksc); jComp.setInputMap(JComponent.WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, imap); } });
Constructor Summary | |
---|---|
MultiMapAdapter() |
Method Summary | |
---|---|
static void |
addActionFilter(ActionFilter filter) |
static void |
fillGlobalMap(MultiInputMap mim, KeyStrokeOptions kso) Replaces the content of the MultiInputMap with the global mappings from a KeyStrokeOptions. |
static void |
fillLocalMap(MultiInputMap mim, KeyStrokeOptions kso, KeyStrokeContext ksc) Replaces the content of a MultiInputMap with the local mappings from a KeyStrokeOptions |
static MultiInputMap |
getGlobalMap(KeyStrokeOptions kso) Extracts the global MultiInputMap from a KeyStrokeOptions and adds a listener to auto-update when it changes |
static MultiInputMap |
getLocalMap(KeyStrokeOptions kso, KeyStrokeContext ksc) Extracts a local MultiInputMap from a KeyStrokeOptions. |
static void |
removeActionFilter(ActionFilter filter) |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public MultiMapAdapter()
Method Detail |
---|
public static void addActionFilter(ActionFilter filter)
public static void removeActionFilter(ActionFilter filter)
public static MultiInputMap getGlobalMap(KeyStrokeOptions kso)
public static void fillGlobalMap(MultiInputMap mim, KeyStrokeOptions kso)
public static MultiInputMap getLocalMap(KeyStrokeOptions kso, KeyStrokeContext ksc)
public static void fillLocalMap(MultiInputMap mim, KeyStrokeOptions kso, KeyStrokeContext ksc)
|
Oracle Fusion Middleware Java API Reference for Oracle Extension SDK 11g Release 2 (11.1.2.2.0) E17493-03 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |