A
drag tracker provides the behavior for dragging selected
figures to the
SelectionTool.
Design Patterns
Strategy
The different behavior states of the selection tool are implemented by
trackers.
Context:
SelectionTool; State:
DragTracker,
HandleTracker,
SelectAreaTracker.
Chain of responsibility
Mouse and keyboard events of the user occur on a drawing view, and are
preprocessed by the
DragTracker of a
SelectionTool.
DragTracker invokes "track" methods on a
Handle which in turn
changes an aspect of a figure.
Client:
SelectionTool; Handler:
DragTracker,
org.jhotdraw.draw.handle.Handle.