|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--junit.extensions.awt.editor.Recorder | +--junit.extensions.awt.editor.KeyStrokeRecorder
Record a key stroke (press and release). Note that this should NOT be used to invoke shortcuts, since the modifiers for those vary by platform.
Constructor Summary | |
KeyStrokeRecorder(Resolver resolver,
ComponentFinder finder,
java.awt.event.ActionListener al)
Create a recorder for capturing mouse button clicks. |
Method Summary | |
protected Step |
createStep()
Create a script step based on the information gathered so far. |
protected void |
eventDispatched(java.awt.AWTEvent event)
Handle an action. |
long |
getEventMask()
Return a mask for events of interest to this recorder. |
java.lang.String |
getName()
For use with actions. |
protected void |
initialize()
Set up state prior to capturing events. |
boolean |
isCancelEvent(java.awt.AWTEvent event)
Since we quit after any key is pressed anyway, we don't need to provide a cancel event. |
protected boolean |
shouldStop()
Override this to indicate when the recording whould terminate (not cancel. |
Methods inherited from class junit.extensions.awt.editor.Recorder |
cancel, eventToString, getFinder, getResolver, record, recordEvent, setResolver, setStatus, simpleClassName |
Methods inherited from class java.lang.Object |
|
Constructor Detail |
public KeyStrokeRecorder(Resolver resolver, ComponentFinder finder, java.awt.event.ActionListener al)
Method Detail |
public java.lang.String getName()
getName
in class Recorder
public long getEventMask()
getEventMask
in class Recorder
protected void initialize()
Recorder
initialize
in class Recorder
protected boolean shouldStop()
Recorder
shouldStop
in class Recorder
protected Step createStep()
Recorder
createStep
in class Recorder
public boolean isCancelEvent(java.awt.AWTEvent event)
isCancelEvent
in class Recorder
protected void eventDispatched(java.awt.AWTEvent event)
Recorder
eventDispatched
in class Recorder
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |