org.openstreetmap.josm.actions
Class ZoomToAction

java.lang.Object
  extended by javax.swing.AbstractAction
      extended by org.openstreetmap.josm.actions.ZoomToAction
All Implemented Interfaces:
java.awt.event.ActionListener, java.io.Serializable, java.lang.Cloneable, java.util.EventListener, javax.swing.Action, javax.swing.event.ListSelectionListener, MapView.LayerChangeListener

public class ZoomToAction
extends javax.swing.AbstractAction
implements MapView.LayerChangeListener, javax.swing.event.ListSelectionListener

See Also:
Serialized Form

Field Summary
private  java.lang.String descriptionInactiveLayer
           
private  java.lang.String descriptionNominal
           
private  java.lang.String descriptionNoSelection
           
private  OsmPrimitivesTable table
           
 
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
 
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
 
Constructor Summary
ZoomToAction(MemberTable table)
           
ZoomToAction(NodeListTable table)
           
ZoomToAction(OsmPrimitivesTable table, java.lang.String descriptionNominal, java.lang.String descriptionInactiveLayer, java.lang.String descriptionNoSelection)
           
ZoomToAction(RelationMemberTable table)
           
 
Method Summary
 void actionPerformed(java.awt.event.ActionEvent e)
           
 void activeLayerChange(Layer oldLayer, Layer newLayer)
          Notifies this listener that the active layer has changed.
 void layerAdded(Layer newLayer)
          Notifies this listener that a layer has been added.
 void layerRemoved(Layer oldLayer)
          Notifies this listener that a layer has been removed.
protected  void updateEnabledState()
           
 void valueChanged(javax.swing.event.ListSelectionEvent e)
           
 
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

table

private final OsmPrimitivesTable table

descriptionNominal

private final java.lang.String descriptionNominal

descriptionInactiveLayer

private final java.lang.String descriptionInactiveLayer

descriptionNoSelection

private final java.lang.String descriptionNoSelection
Constructor Detail

ZoomToAction

public ZoomToAction(OsmPrimitivesTable table,
                    java.lang.String descriptionNominal,
                    java.lang.String descriptionInactiveLayer,
                    java.lang.String descriptionNoSelection)

ZoomToAction

public ZoomToAction(MemberTable table)

ZoomToAction

public ZoomToAction(RelationMemberTable table)

ZoomToAction

public ZoomToAction(NodeListTable table)
Method Detail

actionPerformed

public void actionPerformed(java.awt.event.ActionEvent e)
Specified by:
actionPerformed in interface java.awt.event.ActionListener

updateEnabledState

protected void updateEnabledState()

valueChanged

public void valueChanged(javax.swing.event.ListSelectionEvent e)
Specified by:
valueChanged in interface javax.swing.event.ListSelectionListener

activeLayerChange

public void activeLayerChange(Layer oldLayer,
                              Layer newLayer)
Description copied from interface: MapView.LayerChangeListener
Notifies this listener that the active layer has changed.

Specified by:
activeLayerChange in interface MapView.LayerChangeListener
Parameters:
oldLayer - The previous active layer
newLayer - The new activer layer

layerAdded

public void layerAdded(Layer newLayer)
Description copied from interface: MapView.LayerChangeListener
Notifies this listener that a layer has been added.

Specified by:
layerAdded in interface MapView.LayerChangeListener
Parameters:
newLayer - The new added layer

layerRemoved

public void layerRemoved(Layer oldLayer)
Description copied from interface: MapView.LayerChangeListener
Notifies this listener that a layer has been removed.

Specified by:
layerRemoved in interface MapView.LayerChangeListener
Parameters:
oldLayer - The old removed layer


JOSM