public class ParallelWayAction extends MapMode implements AWTEventListener, MapViewPaintable, Preferences.PreferenceChangedListener
| Modifier and Type | Class and Description |
|---|---|
private static class |
ParallelWayAction.Mode |
scchangeSupport, enabledACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON| Constructor and Description |
|---|
ParallelWayAction(MapFrame mapFrame) |
actionPerformed, mouseClicked, mouseEntered, mouseExited, mouseMoved, requestFocusInMapView, updateKeyModifiers, updateKeyModifiers, updateKeyModifiers, updateStatusLinegetCurrentDataSet, getEditLayer, getShortcut, initEnabledState, installAdapters, setTooltip, updateEnabledState, updateEnabledStateaddPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabledprivate ParallelWayAction.Mode mode
private boolean copyTags
private boolean copyTagsDefault
private boolean snap
private boolean snapDefault
private double snapThreshold
private double snapDistanceMetric
private double snapDistanceImperial
private double snapDistanceChinese
private double snapDistanceNautical
private ModifiersSpec snapModifierCombo
private ModifiersSpec copyTagsModifierCombo
private ModifiersSpec addToSelectionModifierCombo
private ModifiersSpec toggleSelectedModifierCombo
private ModifiersSpec setSelectedModifierCombo
private int initialMoveDelay
private Point mousePressedPos
private boolean mouseIsDown
private long mousePressedTime
private boolean mouseHasBeenDragged
private WaySegment referenceSegment
private ParallelWays pWays
private Set<Way> sourceWays
private EastNorth helperLineStart
private EastNorth helperLineEnd
Stroke helpLineStroke
Stroke refLineStroke
public ParallelWayAction(MapFrame mapFrame)
public void enterMode()
MapModepublic void exitMode()
MapModepublic String getModeHelpText()
getModeHelpText in class MapModeprivate void updateAllPreferences()
private void updateModeLocalPreferences()
public boolean layerIsSupported(Layer layer)
layerIsSupported in class MapModepublic void eventDispatched(AWTEvent e)
eventDispatched in interface AWTEventListenerprivate boolean updateModifiersState(InputEvent e)
private void updateCursor()
private void setMode(ParallelWayAction.Mode mode)
private boolean sanityCheck()
public void mousePressed(MouseEvent e)
mousePressed in interface MouseListenermousePressed in class MapModepublic void mouseReleased(MouseEvent e)
mouseReleased in interface MouseListenermouseReleased in class MapModeprivate void removeWayHighlighting(Collection<Way> ways)
public void mouseDragged(MouseEvent e)
mouseDragged in interface MouseMotionListenermouseDragged in class MapModeprivate boolean matchesCurrentModifiers(ModifiersSpec spec)
public void paint(Graphics2D g, MapView mv, Bounds bbox)
MapViewPaintablepaint in interface MapViewPaintablemv - The object that can translate GeoPoints to screen coordinates.private boolean isModifiersValidForDragMode()
private void updateFlagsOnlyChangeableOnPress()
private void updateFlagsChangeableAlways()
private void addSourceWay(Way w)
private void removeSourceWay(Way w)
private void clearSourceWays()
private void resetMouseTrackingState()
private boolean initParallelWays(Point p, boolean copyTags)
private String getStringPref(String subKey, String def)
public void preferenceChanged(Preferences.PreferenceChangeEvent e)
preferenceChanged in interface Preferences.PreferenceChangedListenerpublic void destroy()
Destroyabledestroy in interface Destroyabledestroy in class JosmAction