sub_arctic.input
Class click_track_agent
java.lang.Object
|
+--sub_arctic.input.dispatch_agent
|
+--sub_arctic.input.focus_dispatch_agent
|
+--sub_arctic.input.click_track_agent
- public class click_track_agent
- extends focus_dispatch_agent
This class implements a focus based agent that tracks (dispatches, but
never consumes) mouse button press and release events. This is used by
things that need to hear about presses or releases that they wouldn't
normally directly receive (i.e. to reset something).
This agent dispatches under the click_tracking input protocol.
Field Summary |
protected java.lang.reflect.Method |
track_click
Store the reference to the method object representing this object's
protocol. |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
track_click
protected java.lang.reflect.Method track_click
- Store the reference to the method object representing this object's
protocol.
click_track_agent
public click_track_agent()
- Default constructor
allowable_focus
public boolean allowable_focus(focusable candidate_obj)
- Allow objects in this focus set only if they implement the
click_tracking interface.
- Parameters:
focusable
- candidate_obj object we are testing for eligibility- Returns:
- boolean indicating if object may be added to focus
- Overrides:
- allowable_focus in class focus_dispatch_agent
event_is_useful
public boolean event_is_useful(event evt)
- Only interested in mouse button moves.
- Parameters:
event
- evt the event we are expressing interest or non-interest in.- Returns:
- boolean indicating whether we want the event.
- Overrides:
- event_is_useful in class dispatch_agent
dispatch_event
public boolean dispatch_event(event evt,
java.lang.Object user_info,
interactor to_obj,
int seq_num)
- Dispatch an event passed to us by our policy.
- Parameters:
event
- evt event that we are dispatching.Object
- user_info uninterpreted information to pass with event.interactor
- to_obj ignored.int
- seq_num ignored.- Returns:
- boolean indicating whether event was dispatched and consumed.
- Overrides:
- dispatch_event in class focus_dispatch_agent