|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object | +--com.monkeycoder.monkeynes.gui.ButtonMap
This class acts as a mapping between keyboard keys and NES controller buttons.
Originally part of the MonkeyNES project.
| Constructor Summary | |
ButtonMap()
Creates a new empty ButtonMap. |
|
| Method Summary | |
void |
addMapping(int inKeyCode,
int inButton)
Adds a new mapping into this ButtonMap. |
int |
getButton(int inKeyCode)
Gets the NES button ID for a given key code. |
String |
toString()
Creates a String containing all the mappings in this ButtonMap. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public ButtonMap()
| Method Detail |
public void addMapping(int inKeyCode,
int inButton)
inKeyCode - The keyboard key code.inButton - The ID of the NES button.public int getButton(int inKeyCode)
inKeyCode - The keyboard key code.
public String toString()
toString in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||