Added facilities for a simple robot player to optionally run rampant in
the sword game. git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@756 542714f4-19e9-0310-aa3c-eee0fc999fb1
This commit is contained in:
@@ -1,8 +1,10 @@
|
||||
//
|
||||
// $Id: KeyTranslator.java,v 1.1 2001/12/12 16:55:06 shaper Exp $
|
||||
// $Id: KeyTranslator.java,v 1.2 2001/12/12 18:09:20 shaper Exp $
|
||||
|
||||
package com.threerings.yohoho.puzzle.util;
|
||||
|
||||
import java.util.Iterator;
|
||||
|
||||
/**
|
||||
* The key translator interface provides a means whereby the keyboard
|
||||
* manager can map a key code to the logical {@link
|
||||
@@ -12,9 +14,9 @@ public interface KeyTranslator
|
||||
{
|
||||
/**
|
||||
* Returns whether there is an action command for the key
|
||||
* corresponding to the given keycode. The translator may have a
|
||||
* mapping for an action command for a key press or a key release of
|
||||
* the key, or both.
|
||||
* corresponding to the given keycode. The translator may have an
|
||||
* action command for either a key press or a key release of the key,
|
||||
* or both.
|
||||
*/
|
||||
public boolean hasCommand (int keyCode);
|
||||
|
||||
@@ -31,4 +33,16 @@ public interface KeyTranslator
|
||||
* if there is no associated command.
|
||||
*/
|
||||
public String getReleaseCommand (int keyCode);
|
||||
|
||||
/**
|
||||
* Returns an iterator that iterates over the available press
|
||||
* commands.
|
||||
*/
|
||||
public Iterator enumeratePressCommands ();
|
||||
|
||||
/**
|
||||
* Returns an iterator that iterates over the available release
|
||||
* commands.
|
||||
*/
|
||||
public Iterator enumerateReleaseCommands ();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user