public class TICKeyEvent extends TICInputEvent
Constructor and Description |
---|
TICKeyEvent(TICComponent source,
int id,
long time,
int modifiers,
int keyCode,
int keyLocation,
char keyCharacter) |
Modifier and Type | Method and Description |
---|---|
TICKeyEvent |
clone() |
TICKeyEvent |
cloneWithNewSource(TICComponent source)
Creates a copy of this event with all properties set to identical values but with a
different source.
|
boolean |
equals(java.lang.Object obj) |
char |
getKeyCharacter() |
int |
getKeyCode() |
int |
getKeyLocation()
Returns the location of the key that was pressed.
|
int |
hashCode() |
getID, getModifiers, getTime, isAltDown, isAltGraphDown, isControlDown, isMenuShortcutKeyDown, isMetaDown, isMouseButton1Down, isMouseButton2Down, isMouseButton3Down, isShiftDown
public TICKeyEvent(TICComponent source, int id, long time, int modifiers, int keyCode, int keyLocation, char keyCharacter)
public int getKeyCode()
public int getKeyLocation()
KeyEvent#KEY_LOCATION_STANDARD
,
KeyEvent#KEY_LOCATION_LEFT
, KeyEvent#KEY_LOCATION_RIGHT
, KeyEvent#KEY_LOCATION_NUMPAD
)public char getKeyCharacter()
public TICKeyEvent cloneWithNewSource(TICComponent source)
TICEvent
cloneWithNewSource
in class TICInputEvent
source
- the source component to be used for the created copypublic TICKeyEvent clone()
clone
in class TICInputEvent
public int hashCode()
hashCode
in class TICInputEvent
public boolean equals(java.lang.Object obj)
equals
in class TICInputEvent