talx x1.0.5

test.constraint
Class PassOnKeyPressAndTimer

java.lang.Object
  extended byconstraint.ConstraintAdapter
      extended bytest.constraint.PassOnKeyPressAndTimer
All Implemented Interfaces:
Constraint, ConstraintConstants, SettingsConstants, StateConstants

public class PassOnKeyPressAndTimer
extends ConstraintAdapter

Marks task as successful when the user presses the given key. The value can be one of:


The completion string produced by this constraint consists of the following tokens:
  1. The constraint class name
  2. The value of the constraint


Field Summary
static java.lang.String BACKSPACE
           
static java.lang.String DELETE
           
static java.lang.String DOWN
           
static java.lang.String END
           
static java.lang.String HOME
           
static java.lang.String LEFT
           
static java.lang.String PAGE_DOWN
           
static java.lang.String PAGE_UP
           
static java.lang.String RETURN
           
static java.lang.String RIGHT
           
static java.lang.String TAB
           
static java.lang.String TIMER_EXPIRE
          action key for timer expiring.
static java.lang.String UP
           
 
Fields inherited from interface constraint.ConstraintConstants
ACTION_COMMAND_KEY, ACTION_TYPE_SOUND_FINISHED, COMPONENT_FINGER_POSITION, COMPONENT_FINGER_PRESS_POSITION, COMPONENT_HORIZONTAL_ARROW_POSITION, COMPONENT_INSTRUCTION_BACKGROUND_COLOR, COMPONENT_INSTRUCTION_TEXT, COMPONENT_INSTRUCTION_TEXT_ATTRIBUTES, COMPONENT_INSTRUCTION_TEXT_COLOR, COMPONENT_INSTRUCTION_TEXT_FONT_FACE, COMPONENT_INSTRUCTION_TEXT_SIZE, COMPONENT_MOUSE_FINGER_POSITION, COMPONENT_SOUND, COMPONENT_SOUND_IS_PLAYING, COMPONENT_SOUND_QUIT, COMPONENT_TIMER, COMPONENT_VERTICAL_ARROW_POSITION, DIALOG, HIDE_BULLSEYE, LESSON_STOP_ACTION, MOUSE_BULLSEYE, MOUSE_FINGER_IMAGE, NO_TOKEN, PREVIOUS_TASK_COMPLETION_REASON, PROGRESS_PANEL_VISIBLITY, SHOW_BULLSEYE, SKIP_TASK_ACTION, TAL_DIALOG, TASK_FAIL_COUNT, TASK_STATUS, TASK_SUCCEED_COUNT, YES_TOKEN
 
Fields inherited from interface controller.StateConstants
ACTION, ACTION_TYPE_CONTINUE, ACTION_TYPE_GOTO, ACTION_TYPE_IGNORE, ACTION_TYPE_PANIC, ACTION_TYPE_QUIT, ACTION_TYPE_RESTART, ACTION_TYPE_REVIEW, ACTION_TYPE_SKIP_DRILL, ACTION_TYPE_SKIP_SKILL, ACTION_TYPE_SKIP_TASK, ACTION_TYPE_TASK_STARTED, ACTION_TYPE_TRAIN, CALLBACK_COMMAND, FIRST_CALLBACK, FOURTH_CALLBACK, SECOND_CALLBACK, THIRD_CALLBACK
 
Fields inherited from interface util.SettingsConstants
ALTERNATIVE_BACKGROUND_COLOR, ALTERNATIVE_BACKGROUND_COLOR_ALIAS, ALTERNATIVE_FONT_ATTRIBUTES, ALTERNATIVE_FONT_ATTRIBUTES_ALIAS, ALTERNATIVE_FONT_COLOR, ALTERNATIVE_FONT_COLOR_ALIAS, CARET_BLINK_RATE, CARET_COLOR, CARET_WIDTH, DECORATED, DEFAULT_UI_STATE_CLASS, FONT_FACE, FONT_FACE_ALIAS, FONT_SIZE, FONT_SIZE_ALIAS, INNER_BACKGROUND_COLOR, INSTRUCTION_BACKGROUND_COLOR, INSTRUCTION_BACKGROUND_COLOR_ALIAS, INSTRUCTION_FONT_ATTRIBUTES, INSTRUCTION_FONT_ATTRIBUTES_ALIAS, INSTRUCTION_FONT_COLOR, INSTRUCTION_FONT_COLOR_ALIAS, LARGE_FONT_SIZE, LARGE_FONT_SIZE_ALIAS, LESSON_UI_STATE_CLASS, LOGGER_CLASS, LOGGER_DIRECTORY, LOGGER_PARAMS, SAVE_FILENAME, SCREEN_PERCENT, SKILL_LATTICE_FILENAME, SMALL_FONT_SIZE, SMALL_FONT_SIZE_ALIAS, STATS_FILENAME, TAL_SETTINGS_FILENAME, TITLE, TITLE_ALIAS, TITLE_ICON, TITLE_ICON_ALIAS, TRAINER_UI_STATE_CLASS, USER_ID
 
Constructor Summary
PassOnKeyPressAndTimer()
           
 
Method Summary
 void processActionEvent(java.awt.event.ActionEvent ev, TaskProperties tp)
           
 void processKeyEvent(java.awt.event.KeyEvent ev, TaskProperties tp)
          When key events get to the constraint, they have already been consumed.
 
Methods inherited from class constraint.ConstraintAdapter
fireAutoAction, getIntValue, getType, getValue, process, processInit, processMouseEvent, setValue, splitPairs, startAutoAction, stopAutoAction, stringToRGB, toString, valueContains
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

TIMER_EXPIRE

public static final java.lang.String TIMER_EXPIRE
action key for timer expiring.

See Also:
Constant Field Values

UP

public static final java.lang.String UP
See Also:
Constant Field Values

DOWN

public static final java.lang.String DOWN
See Also:
Constant Field Values

LEFT

public static final java.lang.String LEFT
See Also:
Constant Field Values

RIGHT

public static final java.lang.String RIGHT
See Also:
Constant Field Values

RETURN

public static final java.lang.String RETURN
See Also:
Constant Field Values

BACKSPACE

public static final java.lang.String BACKSPACE
See Also:
Constant Field Values

TAB

public static final java.lang.String TAB
See Also:
Constant Field Values

HOME

public static final java.lang.String HOME
See Also:
Constant Field Values

END

public static final java.lang.String END
See Also:
Constant Field Values

DELETE

public static final java.lang.String DELETE
See Also:
Constant Field Values

PAGE_DOWN

public static final java.lang.String PAGE_DOWN
See Also:
Constant Field Values

PAGE_UP

public static final java.lang.String PAGE_UP
See Also:
Constant Field Values
Constructor Detail

PassOnKeyPressAndTimer

public PassOnKeyPressAndTimer()
Method Detail

processKeyEvent

public void processKeyEvent(java.awt.event.KeyEvent ev,
                            TaskProperties tp)
Description copied from class: ConstraintAdapter
When key events get to the constraint, they have already been consumed. Thus, a constraint may do anything it wants with the characters, but nothing will happen automatically.

Overrides:
processKeyEvent in class ConstraintAdapter

processActionEvent

public void processActionEvent(java.awt.event.ActionEvent ev,
                               TaskProperties tp)
Overrides:
processActionEvent in class ConstraintAdapter

talx x1.0.5

© 2001-2005 University of Oregon.
Eugene OR 97403, U.S.A. All Rights Reserved.