skrueger.geotools
Interface XMapPaneAction

All Known Implementing Classes:
XMapPaneAction_Pan, XMapPaneAction_Select, XMapPaneAction_Select.All, XMapPaneAction_Select.OneFromTop, XMapPaneAction_Select.Top, XMapPaneAction_Zoom, XMapPaneAction_Zoom.In, XMapPaneAction_Zoom.Out, XMapPaneActionAdapter

public interface XMapPaneAction

Defines an action (e.g. Zoom in, zoom out, drag) when a click, drag or window selection is performed on a XMapPane.

Author:
Martin Schmitz (University of Bonn/Germany)

Field Summary
static XMapPaneAction_Pan PAN
          This action can be assigned to any MouseInputType to perform panning on a Map
static XMapPaneAction_Select.All SELECT_ALL
          This action can be assigned to fire events for any number of feature from all layers.
static XMapPaneAction_Select.OneFromTop SELECT_ONE_FROM_TOP
          This action can be assigned to fire selection events for one feature from the top layer.
static XMapPaneAction_Select.Top SELECT_TOP
          This action can be assigned to fire events for any number of feature from the top layer.
static XMapPaneAction_Zoom ZOOM_IN
          This action can be assigned to any MouseInputType to perform zoom-in
static XMapPaneAction_Zoom ZOOM_OUT
          This action can be assigned to any MouseInputType to perform zoom-out
 
Method Summary
 void performClick(XMapPane mapPane, MouseEvent ev, DirectPosition coord)
          Defines the action in case of a single click on the map.
 void performDragged(XMapPane mapPane, MouseEvent ev, Point dragStartPos, Point dragLastPos, DirectPosition startCoord, DirectPosition endCoord)
          Defines the action in case of a window selection on the map (the moment a drag ends).
 void performDragging(XMapPane mapPane, MouseEvent ev, Point dragStartPos, Point dragLastPos, DirectPosition startCoord, DirectPosition endCoord)
          Defines the action in case of a mouse drag on the map.
 void performKeyboard(XMapPane mapPane, Object param)
          Defines what happens if this action has been triggered by a keyboard-key.
 void performWheel(XMapPane mapPane, MouseWheelEvent ev, DirectPosition coord)
          Defines the action in case of a mouse wheel action on the map (the moment a drag ends).
 

Field Detail

ZOOM_IN

static final XMapPaneAction_Zoom ZOOM_IN
This action can be assigned to any MouseInputType to perform zoom-in


ZOOM_OUT

static final XMapPaneAction_Zoom ZOOM_OUT
This action can be assigned to any MouseInputType to perform zoom-out


PAN

static final XMapPaneAction_Pan PAN
This action can be assigned to any MouseInputType to perform panning on a Map


SELECT_ALL

static final XMapPaneAction_Select.All SELECT_ALL
This action can be assigned to fire events for any number of feature from all layers.


SELECT_ONE_FROM_TOP

static final XMapPaneAction_Select.OneFromTop SELECT_ONE_FROM_TOP
This action can be assigned to fire selection events for one feature from the top layer.


SELECT_TOP

static final XMapPaneAction_Select.Top SELECT_TOP
This action can be assigned to fire events for any number of feature from the top layer.

Method Detail

performClick

void performClick(XMapPane mapPane,
                  MouseEvent ev,
                  DirectPosition coord)
Defines the action in case of a single click on the map. Called by ### XMapPaneMouseAdapter ### on MouseInputType.LClick and MouseInputType.RClick.

Parameters:
mapPane - map pane the action should be performed on
ev - mouse event of the action
coord - geo coordinate the click is performed on

performDragging

void performDragging(XMapPane mapPane,
                     MouseEvent ev,
                     Point dragStartPos,
                     Point dragLastPos,
                     DirectPosition startCoord,
                     DirectPosition endCoord)
Defines the action in case of a mouse drag on the map. This method is called on every mouse motion.

Parameters:
mapPane - map pane the action should be performed on
ev - mouse event of the action
dragStartPos - window position the drag was started (the current position can be determined from the mouse event)
startCoord - geo coordinate the drag was started
endCoord - geo coordinate the drag is currently moved over

performDragged

void performDragged(XMapPane mapPane,
                    MouseEvent ev,
                    Point dragStartPos,
                    Point dragLastPos,
                    DirectPosition startCoord,
                    DirectPosition endCoord)
Defines the action in case of a window selection on the map (the moment a drag ends).

Parameters:
mapPane - map pane the action should be performed on
ev - mouse event of the action
dragStartPos - window position the window starts (the end position can be determined from the mouse event)
startCoord - geo coordinate the window starts
endCoord - geo coordinate the window ends

performWheel

void performWheel(XMapPane mapPane,
                  MouseWheelEvent ev,
                  DirectPosition coord)
Defines the action in case of a mouse wheel action on the map (the moment a drag ends).

Parameters:
mapPane - map pane the action should be performed on
ev - mouse event of the action
coord - geo coordinate the wheel is turned on

performKeyboard

void performKeyboard(XMapPane mapPane,
                     Object param)
Defines what happens if this action has been triggered by a keyboard-key.

Parameters:
mapPane - map pane the action should be performed on
param - An optinal paramter that can be defined.