Package org.eclipse.gef.handles
Class RelativeHandleLocator
java.lang.Object
org.eclipse.draw2d.RelativeLocator
org.eclipse.gef.handles.RelativeHandleLocator
- All Implemented Interfaces:
org.eclipse.draw2d.Locator
public class RelativeHandleLocator
extends org.eclipse.draw2d.RelativeLocator
Similar to
RelativeLocator
, but adds support for
the HandleBounds
interface. If the reference
figure implements HandleBounds
, then
HandleBounds.getHandleBounds()
will be used as the reference box. If
not, the behavior is the same as that of the superclass.-
Constructor Summary
ConstructorsConstructorDescriptionRelativeHandleLocator
(org.eclipse.draw2d.IFigure reference, int location) Constructs a new locator using the given reference figure and location. -
Method Summary
Modifier and TypeMethodDescriptionprotected org.eclipse.draw2d.geometry.Rectangle
Overridden to check for reference figures implementing theHandleBounds
interface.Methods inherited from class org.eclipse.draw2d.RelativeLocator
getReferenceFigure, relocate, setReferenceFigure
-
Constructor Details
-
RelativeHandleLocator
public RelativeHandleLocator(org.eclipse.draw2d.IFigure reference, int location) Constructs a new locator using the given reference figure and location.- Parameters:
reference
- the reference figurelocation
- one of NORTH, NORTH_EAST, etc.
-
-
Method Details
-
getReferenceBox
protected org.eclipse.draw2d.geometry.Rectangle getReferenceBox()Overridden to check for reference figures implementing theHandleBounds
interface.- Overrides:
getReferenceBox
in classorg.eclipse.draw2d.RelativeLocator
- See Also:
-
RelativeLocator.getReferenceBox()
-