Changeset 33547 in osm for applications/editors/josm/plugins/imagery_offset_db/src/iodb/CalibrationLayer.java
- Timestamp:
- 2017-08-26T21:28:34+02:00 (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/imagery_offset_db/src/iodb/CalibrationLayer.java
r32910 r33547 19 19 import javax.swing.Icon; 20 20 21 import org.openstreetmap.josm.Main;22 21 import org.openstreetmap.josm.actions.AutoScaleAction; 23 22 import org.openstreetmap.josm.data.Bounds; 24 23 import org.openstreetmap.josm.data.coor.LatLon; 25 24 import org.openstreetmap.josm.data.osm.visitor.BoundingXYVisitor; 25 import org.openstreetmap.josm.gui.MainApplication; 26 26 import org.openstreetmap.josm.gui.MapView; 27 27 import org.openstreetmap.josm.gui.dialogs.LayerListDialog; … … 152 152 double lat = 0.0; 153 153 double lon = 0.0; 154 for ( int i = 0; i <geometry.length; i++) {155 lon += geometry[i].lon();156 lat += geometry[i].lat();154 for (LatLon ll : geometry) { 155 lon += ll.lon(); 156 lat += ll.lat(); 157 157 } 158 158 center = new LatLon(lat / geometry.length, lon / geometry.length); 159 159 } 160 Main .map.mapView.zoomTo(center);160 MainApplication.getMap().mapView.zoomTo(center); 161 161 } 162 162 … … 178 178 public void actionPerformed(ActionEvent e) { 179 179 color = c; 180 Main .map.mapView.repaint();180 MainApplication.getMap().mapView.repaint(); 181 181 } 182 182 }
Note:
See TracChangeset
for help on using the changeset viewer.
