workspace.typeblocking
Class KeyInputMap

java.lang.Object
  extended by workspace.typeblocking.KeyInputMap

public class KeyInputMap
extends java.lang.Object

The KeyInputMap manages the processing of particular keys and delegates the task of performing an action to the TypeBlockManager. In a sense, the KeyInputMap assists in mapping a character to an Action.


Method Summary
protected static void enableDefaultKeyMapping(boolean enable)
          Enables this if and only if enable == true.
static void processKeyChar(java.awt.event.KeyEvent key)
          Processes user-generated keyEvent.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

enableDefaultKeyMapping

protected static void enableDefaultKeyMapping(boolean enable)
Enables this if and only if enable == true. By enabling the default key mapping, generic key to genus mappings are used.

Parameters:
enable -

processKeyChar

public static void processKeyChar(java.awt.event.KeyEvent key)
Processes user-generated keyEvent. This method is intended to react in one of three ways: 1. It should traverse the block canvas; that is, it should move the cursor the the next appropriate block. 2. It should display a graphical interface (also called the "View" interface of TypeBlockManager) to assist the user in selecting the a pre-defined pattern. 3. It should parse the key event and drop down the appropriate block as well as make the needed connections.

Parameters:
key -