Changeset 12630 in josm for trunk/src/org/openstreetmap/josm/actions/mapmode/ParallelWayAction.java
- Timestamp:
- 2017-08-24T00:15:51+02:00 (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/actions/mapmode/ParallelWayAction.java
r12620 r12630 25 25 import javax.swing.JOptionPane; 26 26 27 import org.openstreetmap.josm.Main;28 27 import org.openstreetmap.josm.data.Bounds; 29 28 import org.openstreetmap.josm.data.SystemOfMeasurement; … … 40 39 import org.openstreetmap.josm.data.preferences.IntegerProperty; 41 40 import org.openstreetmap.josm.data.preferences.StrokeProperty; 41 import org.openstreetmap.josm.gui.MainApplication; 42 42 import org.openstreetmap.josm.gui.MapFrame; 43 43 import org.openstreetmap.josm.gui.MapView; … … 172 172 mv.addTemporaryLayer(temporaryLayer); 173 173 174 // //Needed to update the mouse cursor if modifiers are changed when the mouse is motionless175 Main .map.keyDetector.addModifierExListener(this);174 // Needed to update the mouse cursor if modifiers are changed when the mouse is motionless 175 MainApplication.getMap().keyDetector.addModifierExListener(this); 176 176 sourceWays = new LinkedHashSet<>(getLayerManager().getEditDataSet().getSelectedWays()); 177 177 for (Way w : sourceWays) { … … 186 186 mv.removeMouseMotionListener(this); 187 187 mv.removeTemporaryLayer(temporaryLayer); 188 Main.map.statusLine.setDist(-1); 189 Main.map.statusLine.repaint(); 190 Main.map.keyDetector.removeModifierExListener(this); 188 MapFrame map = MainApplication.getMap(); 189 map.statusLine.setDist(-1); 190 map.statusLine.repaint(); 191 map.keyDetector.removeModifierExListener(this); 191 192 removeWayHighlighting(sourceWays); 192 193 pWays = null; … … 217 218 @Override 218 219 public void modifiersExChanged(int modifiers) { 219 if (Main .map== null || mv == null || !mv.isActiveLayerDrawable())220 if (MainApplication.getMap() == null || mv == null || !mv.isActiveLayerDrawable()) 220 221 return; 221 222 … … 431 432 pWays.changeOffset(d); 432 433 433 Main.map.statusLine.setDist(Math.abs(snappedRealD)); 434 Main.map.statusLine.repaint(); 434 MapFrame map = MainApplication.getMap(); 435 map.statusLine.setDist(Math.abs(snappedRealD)); 436 map.statusLine.repaint(); 435 437 temporaryLayer.invalidate(); 436 438 }
Note:
See TracChangeset
for help on using the changeset viewer.