org.geotools.swing.action
Class MapAction

Object
  extended by AbstractAction
      extended by MapAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
Direct Known Subclasses:
InfoAction, PanAction, ResetAction, ZoomInAction, ZoomOutAction

public abstract class MapAction
extends AbstractAction

Base class for map pane actions; just provides a common initializing method and a reference to the map pane being serviced.

Since:
2.6
Author:
Michael Bedward
See Also:
Serialized Form
Module:
modules/unsupported/swing (gt-swing.jar)

Field Summary
 
Fields inherited from class AbstractAction
changeSupport, enabled
 
Fields inherited from interface Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SHORT_DESCRIPTION, SMALL_ICON
 
Constructor Summary
MapAction()
           
 
Method Summary
 JMapPane getMapPane()
          Get the map pane that this Action is working with
protected  void init(JMapPane mapPane, String toolName, String toolTip, String iconImage)
          Called by sub-classes to set the map pane field and initialize the control action properties
 
Methods inherited from class AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
 
Methods inherited from class Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface ActionListener
actionPerformed
 

Constructor Detail

MapAction

public MapAction()
Method Detail

init

protected void init(JMapPane mapPane,
                    String toolName,
                    String toolTip,
                    String iconImage)
Called by sub-classes to set the map pane field and initialize the control action properties

Parameters:
mapPane - the map pane that this action is working with
toolName - short (single word) tool name; may be null
toolTip - brief tool description for GUI tool tip
iconImage - path to the icon to display on the control

getMapPane

public JMapPane getMapPane()
Get the map pane that this Action is working with

Returns:
the map pane


Copyright © 1996-2010 Geotools. All Rights Reserved.