Class PlayHeadDragMode
- java.lang.Object
-
- javax.swing.AbstractAction
-
- org.openstreetmap.josm.actions.JosmAction
-
- org.openstreetmap.josm.actions.mapmode.MapMode
-
- org.openstreetmap.josm.actions.mapmode.PlayHeadDragMode
-
- All Implemented Interfaces:
ActionListener
,MouseListener
,MouseMotionListener
,Serializable
,Cloneable
,EventListener
,Action
,PreferenceChangedListener
,Destroyable
public class PlayHeadDragMode extends MapMode
Singleton marker class to track position of audio.- See Also:
- Serialized Form
-
-
Nested Class Summary
-
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 boolean
dragging
private Point
mousePos
private Point
mouseStart
private PlayHeadMarker
playHeadMarker
-
Fields inherited from class org.openstreetmap.josm.actions.JosmAction
sc
-
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
Constructors Constructor Description PlayHeadDragMode(PlayHeadMarker m)
Constructs a newPlayHeadDragMode
.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
enterMode()
Makes this map mode active.void
exitMode()
Makes this map mode inactive.String
getModeHelpText()
Returns a short translated help message describing how this map mode can be used, to be displayed in status line.void
mouseDragged(MouseEvent ev)
void
mousePressed(MouseEvent ev)
void
mouseReleased(MouseEvent ev)
-
Methods inherited from class org.openstreetmap.josm.actions.mapmode.MapMode
actionPerformed, isEditableDataLayer, layerIsSupported, mouseClicked, mouseEntered, mouseExited, mouseMoved, preferenceChanged, readPreferences, requestFocusInMapView, updateKeyModifiers, updateKeyModifiers, updateKeyModifiers, updateKeyModifiersEx, updateStatusLine
-
Methods inherited from class org.openstreetmap.josm.actions.JosmAction
buildActiveLayerChangeAdapter, buildLayerChangeAdapter, checkAndConfirmOutlyingOperation, destroy, getLayerManager, getShortcut, initEnabledState, installAdapters, listenToLayerChange, listenToSelectionChange, setHelpId, setToolbarId, setTooltip, updateEnabledState, updateEnabledState, updateEnabledStateOnCurrentSelection, updateEnabledStateOnCurrentSelection, updateEnabledStateOnModifiableSelection, waitFuture
-
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
-
-
-
-
Field Detail
-
dragging
private boolean dragging
-
mouseStart
private Point mouseStart
-
playHeadMarker
private final transient PlayHeadMarker playHeadMarker
-
-
Constructor Detail
-
PlayHeadDragMode
public PlayHeadDragMode(PlayHeadMarker m)
Constructs a newPlayHeadDragMode
.- Parameters:
m
- Audio marker
-
-
Method Detail
-
enterMode
public void enterMode()
Description copied from class:MapMode
Makes this map mode active.
-
exitMode
public void exitMode()
Description copied from class:MapMode
Makes this map mode inactive.
-
mousePressed
public void mousePressed(MouseEvent ev)
- Specified by:
mousePressed
in interfaceMouseListener
- Overrides:
mousePressed
in classMapMode
-
mouseDragged
public void mouseDragged(MouseEvent ev)
- Specified by:
mouseDragged
in interfaceMouseMotionListener
- Overrides:
mouseDragged
in classMapMode
-
mouseReleased
public void mouseReleased(MouseEvent ev)
- Specified by:
mouseReleased
in interfaceMouseListener
- Overrides:
mouseReleased
in classMapMode
-
getModeHelpText
public String getModeHelpText()
Description copied from class:MapMode
Returns a short translated help message describing how this map mode can be used, to be displayed in status line.- Overrides:
getModeHelpText
in classMapMode
- Returns:
- a short translated help message describing how this map mode can be used
-
-