Move mercator transforms to Projection.js.

The SphericalMercator mixin is not required for coordinate transforms.  Default transforms included whenever Projection.js is included.
This commit is contained in:
Tim Schaub
2012-01-16 22:39:44 -07:00
parent 0e8b3f2ff8
commit 4b949176d3
5 changed files with 75 additions and 125 deletions
+1 -5
View File
@@ -65,11 +65,7 @@
// works correctly both ways.
var gLatLng = new google.maps.LatLng(50,100);
// v3 uses sphericalMercator by default
var correspondingOLLonLat = new OpenLayers.LonLat(100,50).transform(
new OpenLayers.Projection("EPSG:4326"),
map.getProjectionObject()
);
var correspondingOLLonLat = layer.forwardMercator(100, 50);
olLonLat = layer.getOLLonLatFromMapObjectLonLat(gLatLng);
t.ok(olLonLat.equals(correspondingOLLonLat), "Translation from GLatLng to OpenLayers.LonLat works");