Class enchant.KeyboardInputManager
Class that manage keyboard input.
- Defined in: enchant.js
- Extends enchant.BinaryInputManager
Constructor Attributes | Constructor Name and Description |
---|---|
enchant.KeyboardInputManager(dom, flagStore)
|
- Fields borrowed from class enchant.BinaryInputManager:
- activeEventNameSuffix, activeInputsNum, inactiveEventNameSuffix
- Fields borrowed from class enchant.InputManager:
- broadcastTarget, source, valueStore
Method Summary
Method Attributes | Method Name and Description |
---|---|
keybind(keyCode, name)
Call enchant.BinaryInputManager#bind with BinaryInputSource equivalent of key code.
|
|
keyunbind(keyCode)
Call enchant.BinaryInputManager#unbind with BinaryInputSource equivalent of key code.
|
- Methods borrowed from class enchant.BinaryInputManager:
- bind
- changeState
- unbind
- Methods borrowed from class enchant.InputManager:
- addBroadcastTarget
- broadcastEvent
- removeBroadcastTarget
- Methods borrowed from class enchant.EventTarget:
- addEventListener
- clearEventListener
- dispatchEvent
- on
- removeEventListener
Class Detail
enchant.KeyboardInputManager(dom, flagStore)
- Parameters:
- {HTMLElement} dom
- element that will be watched.
- {*} flagStore
- object that store input flag.
Method Detail
-
keybind(keyCode, name)Call enchant.BinaryInputManager#bind with BinaryInputSource equivalent of key code.
- Parameters:
- {Number} keyCode
- key code.
- {String} name
- input name.
-
keyunbind(keyCode)Call enchant.BinaryInputManager#unbind with BinaryInputSource equivalent of key code.
- Parameters:
- {Number} keyCode
- key code.