VASSAL.counters
Class KeyCommand

java.lang.Object
  |
  +--javax.swing.AbstractAction
        |
        +--VASSAL.counters.KeyCommand
All Implemented Interfaces:
javax.swing.Action, java.awt.event.ActionListener, java.lang.Cloneable, java.util.EventListener, java.io.Serializable

public class KeyCommand
extends javax.swing.AbstractAction

See Also:
Serialized Form

Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
 
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SHORT_DESCRIPTION, SMALL_ICON
 
Constructor Summary
KeyCommand(java.lang.String name, javax.swing.KeyStroke key, GamePiece target)
           
 
Method Summary
 void actionPerformed(java.awt.event.ActionEvent evt)
           
 javax.swing.KeyStroke getKeyStroke()
           
 java.lang.String getName()
           
 GamePiece getTarget()
           
 boolean matches(javax.swing.KeyStroke key)
           
 
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

KeyCommand

public KeyCommand(java.lang.String name,
                  javax.swing.KeyStroke key,
                  GamePiece target)
Method Detail

getName

public java.lang.String getName()

matches

public boolean matches(javax.swing.KeyStroke key)

getKeyStroke

public javax.swing.KeyStroke getKeyStroke()

getTarget

public GamePiece getTarget()

actionPerformed

public void actionPerformed(java.awt.event.ActionEvent evt)
Overrides:
actionPerformed in class javax.swing.AbstractAction