public class WCSZoomPixelCursorListener extends Object implements PointListener
Listener that executes a zoom in operation in the associated MapControl
,
having as center the point selected.
Listens a single click of any mouse's button.
The zoom in factor will depend on the maximum resolution of the WCS layers in
the MapControl
.
Constructor and Description |
---|
WCSZoomPixelCursorListener(MapControl mc)
Creates a new
WCSZoomPixelCursorListener object. |
Modifier and Type | Method and Description |
---|---|
boolean |
cancelDrawing()
Determines if the drawing process that this tool executes on the
MapControl
instance could be canceled or not. |
Cursor |
getCursor() |
Image |
getImageCursor()
Gets the
Cursor associated to this tool. |
void |
point(PointEvent event)
Called when one click is pressed on the associated
MapControl , or the location of the cursor
of the mouse has changed on it. |
void |
pointDoubleClick(PointEvent event)
Called when a double click is pressed on the associated
MapControl . |
public WCSZoomPixelCursorListener(MapControl mc)
Creates a new WCSZoomPixelCursorListener
object.
mc
- the MapControl
where be applied the changespublic void point(PointEvent event) throws BehaviorException
PointListener
Called when one click is pressed on the associated MapControl
, or the location of the cursor
of the mouse has changed on it.
point
in interface PointListener
event
- mouse event with the coordinates of the point selected on the associated MapControl
BehaviorException
- will be thrown when fails the process of this toolpublic Cursor getCursor()
public boolean cancelDrawing()
ToolListener
Determines if the drawing process that this tool executes on the MapControl
instance could be canceled or not.
cancelDrawing
in interface ToolListener
true
if is cancellable; otherwise returns false
public void pointDoubleClick(PointEvent event) throws BehaviorException
PointListener
Called when a double click is pressed on the associated MapControl
.
pointDoubleClick
in interface PointListener
event
- mouse event and the coordinates of the point selected on the associated MapControl
BehaviorException
- will be thrown when fails the process of this toolpublic Image getImageCursor()
ToolListener
Gets the Cursor
associated to this tool.
getImageCursor
in interface ToolListener