JHotDraw 6.0b1

org.jhotdraw.figures
Class PolyLineHandle

java.lang.Object
  extended by org.jhotdraw.standard.AbstractHandle
      extended by org.jhotdraw.standard.LocatorHandle
          extended by org.jhotdraw.figures.PolyLineHandle
All Implemented Interfaces:
Handle

public class PolyLineHandle
extends LocatorHandle

A handle for a node on the polyline.


Nested Class Summary
static class PolyLineHandle.UndoActivity
           
 
Field Summary
 
Fields inherited from class org.jhotdraw.standard.AbstractHandle
HANDLESIZE
 
Constructor Summary
PolyLineHandle(PolyLineFigure owner, Locator l, int index)
          Constructs a poly line handle.
 
Method Summary
protected  Undoable createUndoActivity(DrawingView newView, int newPointIndex)
          Factory method for undo activity.
 void invokeEnd(int x, int y, int anchorX, int anchorY, DrawingView view)
          Tracks the end of the interaction.
 void invokeStart(int x, int y, DrawingView view)
          Tracks the start of the interaction.
 void invokeStep(int x, int y, int anchorX, int anchorY, DrawingView view)
          Tracks a step of the interaction.
 
Methods inherited from class org.jhotdraw.standard.LocatorHandle
getCursor, getLocator, locate
 
Methods inherited from class org.jhotdraw.standard.AbstractHandle
containsPoint, displayBox, draw, getUndoActivity, invokeEnd, invokeStart, invokeStep, owner, setUndoActivity
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PolyLineHandle

public PolyLineHandle(PolyLineFigure owner,
                      Locator l,
                      int index)
Constructs a poly line handle.

Parameters:
owner - the owning polyline figure.
l - the locator
index - the index of the node associated with this handle.
Method Detail

invokeStart

public void invokeStart(int x,
                        int y,
                        DrawingView view)
Description copied from interface: Handle
Tracks the start of the interaction. The default implementation does nothing.

Specified by:
invokeStart in interface Handle
Overrides:
invokeStart in class AbstractHandle
Parameters:
x - the x position where the interaction started
y - the y position where the interaction started
view - the handles container
See Also:
Handle.invokeStart(int, int, org.jhotdraw.framework.DrawingView)

invokeStep

public void invokeStep(int x,
                       int y,
                       int anchorX,
                       int anchorY,
                       DrawingView view)
Description copied from class: AbstractHandle
Tracks a step of the interaction.

Specified by:
invokeStep in interface Handle
Overrides:
invokeStep in class AbstractHandle
Parameters:
x - the current x position
y - the current y position
anchorX - the x position where the interaction started
anchorY - the y position where the interaction started
See Also:
Handle.invokeStep(int, int, int, int, org.jhotdraw.framework.DrawingView)

invokeEnd

public void invokeEnd(int x,
                      int y,
                      int anchorX,
                      int anchorY,
                      DrawingView view)
Description copied from class: AbstractHandle
Tracks the end of the interaction.

Specified by:
invokeEnd in interface Handle
Overrides:
invokeEnd in class AbstractHandle
Parameters:
x - the current x position
y - the current y position
anchorX - the x position where the interaction started
anchorY - the y position where the interaction started
See Also:
Handle.invokeEnd(int, int, int, int, org.jhotdraw.framework.DrawingView)

createUndoActivity

protected Undoable createUndoActivity(DrawingView newView,
                                      int newPointIndex)
Factory method for undo activity. To be overriden by subclasses.


JHotDraw 6.0b1