Changeset 12630 in josm for trunk/src/org/openstreetmap/josm/actions/FollowLineAction.java
- Timestamp:
- 2017-08-24T00:15:51+02:00 (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/actions/FollowLineAction.java
r12351 r12630 19 19 import org.openstreetmap.josm.data.osm.OsmPrimitive; 20 20 import org.openstreetmap.josm.data.osm.Way; 21 import org.openstreetmap.josm.gui.MainApplication; 22 import org.openstreetmap.josm.gui.MapFrame; 21 23 import org.openstreetmap.josm.gui.layer.OsmDataLayer; 22 24 import org.openstreetmap.josm.tools.Shortcut; … … 63 65 if (osmLayer == null) 64 66 return; 65 if (!(Main.map.mapMode instanceof DrawAction)) return; // We are not on draw mode 67 MapFrame map = MainApplication.getMap(); 68 if (!(map.mapMode instanceof DrawAction)) return; // We are not on draw mode 66 69 67 70 Collection<Node> selectedPoints = osmLayer.data.getSelectedNodes(); … … 70 73 return; 71 74 72 Node last = ((DrawAction) Main.map.mapMode).getCurrentBaseNode();75 Node last = ((DrawAction) map.mapMode).getCurrentBaseNode(); 73 76 if (last == null) 74 77 return; … … 122 125 // from aerial imagery or GPS tracks. 123 126 if (DrawAction.VIEWPORT_FOLLOWING.get()) { 124 Main.map.mapView.smoothScrollTo(newPoint.getEastNorth());127 map.mapView.smoothScrollTo(newPoint.getEastNorth()); 125 128 } 126 129 }
Note:
See TracChangeset
for help on using the changeset viewer.
