org.jhotdraw.samples.mini
Class SelectionToolSample
java.lang.Object
org.jhotdraw.samples.mini.SelectionToolSample
public class SelectionToolSample
- extends java.lang.Object
SelectionToolSample demonstrates how the SelectionTool works.
Internally, the SelectionTool uses three smaller tools
(named as 'Tracker') to fulfill its task. If the user presses the mouse
button over an empty area of a drawing, the SelectAreaTracker
comes into action. If the user presses the mouse button over a figure, the
DragTracker comes into action. If the user presses the mouse
button over a handle, the HandleTracker comes into action.
You need to edit the source code as marked below.
With this program you can:
- See how the
SelectionTool interacts with a
LineFigure.
- See how the
SelectAreaTracker interacts with a
LineFigure.
- See how the
DragTracker interacts with a
LineFigure.
- See how the
HandleTracker interacts with a
LineFigure.
- Version:
- $Id: SelectionToolSample.java 527 2009-06-07 14:28:19Z rawcoder $
- Author:
- Pondus
|
Method Summary |
static void |
main(java.lang.String[] args)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SelectionToolSample
public SelectionToolSample()
- Creates a new instance of SelectionToolSample
main
public static void main(java.lang.String[] args)