org.springframework.richclient.text
Class TextComponentPopup.DefaultKeymap

java.lang.Object
  extended by org.springframework.richclient.text.TextComponentPopup.DefaultKeymap
All Implemented Interfaces:
Keymap
Enclosing class:
TextComponentPopup

public static class TextComponentPopup.DefaultKeymap
extends Object
implements Keymap

We need this class since keymaps are shared in jvm This class is a 100% copy of the jdk class {@link JTextComponent#DefaultKeymap


Method Summary
 void addActionForKeyStroke(KeyStroke key, Action a)
           
 Action getAction(KeyStroke key)
           
 Action[] getBoundActions()
           
 KeyStroke[] getBoundKeyStrokes()
           
 Action getDefaultAction()
          Fetch the default action to fire if a key is typed (ie a KEY_TYPED KeyEvent is received) and there is no binding for it.
 KeyStroke[] getKeyStrokesForAction(Action a)
           
 String getName()
           
 Keymap getResolveParent()
           
 boolean isLocallyDefined(KeyStroke key)
           
 void removeBindings()
           
 void removeKeyStrokeBinding(KeyStroke key)
           
 void setDefaultAction(Action a)
          Set the default action to fire if a key is typed.
 void setResolveParent(Keymap parent)
           
 String toString()
          String representation of the keymap...
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Method Detail

getDefaultAction

public Action getDefaultAction()
Fetch the default action to fire if a key is typed (ie a KEY_TYPED KeyEvent is received) and there is no binding for it. Typically this would be some action that inserts text so that the keymap doesn't require an action for each possible key.

Specified by:
getDefaultAction in interface Keymap

setDefaultAction

public void setDefaultAction(Action a)
Set the default action to fire if a key is typed.

Specified by:
setDefaultAction in interface Keymap

getName

public String getName()
Specified by:
getName in interface Keymap

getAction

public Action getAction(KeyStroke key)
Specified by:
getAction in interface Keymap

getBoundKeyStrokes

public KeyStroke[] getBoundKeyStrokes()
Specified by:
getBoundKeyStrokes in interface Keymap

getBoundActions

public Action[] getBoundActions()
Specified by:
getBoundActions in interface Keymap

getKeyStrokesForAction

public KeyStroke[] getKeyStrokesForAction(Action a)
Specified by:
getKeyStrokesForAction in interface Keymap

isLocallyDefined

public boolean isLocallyDefined(KeyStroke key)
Specified by:
isLocallyDefined in interface Keymap

addActionForKeyStroke

public void addActionForKeyStroke(KeyStroke key,
                                  Action a)
Specified by:
addActionForKeyStroke in interface Keymap

removeKeyStrokeBinding

public void removeKeyStrokeBinding(KeyStroke key)
Specified by:
removeKeyStrokeBinding in interface Keymap

removeBindings

public void removeBindings()
Specified by:
removeBindings in interface Keymap

getResolveParent

public Keymap getResolveParent()
Specified by:
getResolveParent in interface Keymap

setResolveParent

public void setResolveParent(Keymap parent)
Specified by:
setResolveParent in interface Keymap

toString

public String toString()
String representation of the keymap... potentially a very long string.

Overrides:
toString in class Object


Copyright © 2004-2008 The Spring Framework. All Rights Reserved.