- Timestamp:
- 2012-02-22T19:17:45+01:00 (13 years ago)
- Location:
- trunk/src/org/openstreetmap/josm
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/gui/layer/TMSLayer.java
r4985 r5017 66 66 import org.openstreetmap.josm.data.preferences.IntegerProperty; 67 67 import org.openstreetmap.josm.data.preferences.StringProperty; 68 import org.openstreetmap.josm.data.projection.Epsg4326;69 import org.openstreetmap.josm.data.projection.Mercator;70 68 import org.openstreetmap.josm.data.projection.Projection; 71 69 import org.openstreetmap.josm.gui.MapView; … … 1447 1445 @Override 1448 1446 public boolean isProjectionSupported(Projection proj) { 1449 return proj instanceof Mercator || proj instanceof Epsg4326;1447 return "EPSG:3857".equals(proj.toCode()) || "EPSG:4326".equals(proj.toCode()); 1450 1448 } 1451 1449 -
trunk/src/org/openstreetmap/josm/gui/layer/WMSLayer.java
r4745 r5017 57 57 import org.openstreetmap.josm.data.preferences.BooleanProperty; 58 58 import org.openstreetmap.josm.data.preferences.IntegerProperty; 59 import org.openstreetmap.josm.data.projection.Mercator;60 59 import org.openstreetmap.josm.data.projection.Projection; 61 60 import org.openstreetmap.josm.gui.MapView; … … 1030 1029 List<String> serverProjections = info.getServerProjections(); 1031 1030 return serverProjections.contains(proj.toCode().toUpperCase()) 1032 || (proj instanceof Mercator && serverProjections.contains("EPSG:4326")); 1031 || ("EPSG:3857".equals(proj.toCode()) && (serverProjections.contains("EPSG:4326") || serverProjections.contains("CRS:84"))) 1032 || ("EPSG:4326".equals(proj.toCode()) && serverProjections.contains("CRS:84")); 1033 1033 } 1034 1034 -
trunk/src/org/openstreetmap/josm/io/imagery/WMSGrabber.java
r4857 r5017 31 31 import org.openstreetmap.josm.data.imagery.GeorefImage.State; 32 32 import org.openstreetmap.josm.data.imagery.ImageryInfo; 33 import org.openstreetmap.josm.data.projection.Mercator;34 33 import org.openstreetmap.josm.gui.MapView; 35 34 import org.openstreetmap.josm.gui.layer.WMSLayer; … … 86 85 int wi, int ht) throws MalformedURLException { 87 86 String myProj = Main.getProjection().toCode(); 88 if (!info.getServerProjections().contains(myProj) && (Main.getProjection() instanceof Mercator)) {87 if (!info.getServerProjections().contains(myProj) && "EPSG:3857".equals(Main.getProjection().toCode())) { 89 88 LatLon sw = Main.getProjection().eastNorth2latlon(new EastNorth(w, s)); 90 89 LatLon ne = Main.getProjection().eastNorth2latlon(new EastNorth(e, n)); … … 99 98 } 100 99 101 // Bounding box coordinat s have to be switched for WMS 1.3.0 EPSG:4326.100 // Bounding box coordinates have to be switched for WMS 1.3.0 EPSG:4326. 102 101 // 103 102 // Background:
Note:
See TracChangeset
for help on using the changeset viewer.