Package org.openstreetmap.josm.actions
Class JumpToAction
- java.lang.Object
-
- javax.swing.AbstractAction
-
- org.openstreetmap.josm.actions.JosmAction
-
- org.openstreetmap.josm.actions.JumpToAction
-
- All Implemented Interfaces:
java.awt.event.ActionListener,java.io.Serializable,java.lang.Cloneable,java.util.EventListener,javax.swing.Action,Destroyable
public class JumpToAction extends JosmAction
Allows to jump to a specific location.- Since:
- 2575
- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description (package private) static classJumpToAction.JumpToPositionDialog(package private) classJumpToAction.OsmLonLatListener(package private) classJumpToAction.OsmURLListener-
Nested classes/interfaces inherited from class org.openstreetmap.josm.actions.JosmAction
JosmAction.ActiveLayerChangeAdapter, JosmAction.LayerChangeAdapter, JosmAction.SelectionChangeAdapter
-
-
Field Summary
Fields Modifier and Type Field Description private JosmTextFieldlatprivate JosmTextFieldlonprivate JosmTextFieldplaceprivate JosmTextFieldurlprivate JosmTextFieldzm-
Fields inherited from class org.openstreetmap.josm.actions.JosmAction
sc
-
-
Constructor Summary
Constructors Constructor Description JumpToAction()Constructs a newJumpToAction.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidactionPerformed(java.awt.event.ActionEvent e)private voidparseURL()private voidsetBounds(Bounds b)voidshowJumpToDialog()Displays the "Jump to" dialog.protected voidupdateEnabledState()Override in subclasses to update the enabled state of the action when something in the JOSM state changes, i.e.private voidupdateUrl(boolean force)-
Methods inherited from class org.openstreetmap.josm.actions.JosmAction
buildActiveLayerChangeAdapter, buildLayerChangeAdapter, checkAndConfirmOutlyingOperation, destroy, getLayerManager, getShortcut, initEnabledState, installAdapters, listenToLayerChange, listenToSelectionChange, setHelpId, setToolbarId, setTooltip, updateEnabledState, updateEnabledStateOnCurrentSelection, updateEnabledStateOnCurrentSelection, updateEnabledStateOnModifiableSelection, waitFuture
-
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
-
-
-
-
Field Detail
-
url
private final JosmTextField url
-
place
private final JosmTextField place
-
lat
private final JosmTextField lat
-
lon
private final JosmTextField lon
-
zm
private final JosmTextField zm
-
-
Constructor Detail
-
JumpToAction
public JumpToAction()
Constructs a newJumpToAction.
-
-
Method Detail
-
showJumpToDialog
public void showJumpToDialog()
Displays the "Jump to" dialog.
-
parseURL
private void parseURL()
-
updateUrl
private void updateUrl(boolean force)
-
actionPerformed
public void actionPerformed(java.awt.event.ActionEvent e)
-
updateEnabledState
protected void updateEnabledState()
Description copied from class:JosmActionOverride in subclasses to update the enabled state of the action when something in the JOSM state changes, i.e. when a layer is removed or added. SeeJosmAction.updateEnabledState(Collection)to respond to changes in the collection of selected primitives. Default behavior is empty.- Overrides:
updateEnabledStatein classJosmAction- See Also:
JosmAction.updateEnabledState(Collection),JosmAction.initEnabledState(),JosmAction.listenToLayerChange()
-
-