[OpenLayers-Commits] r11492 - in sandbox/ahocevar/layercontainer:
lib/OpenLayers tests/Layer/Google
commits-20090109 at openlayers.org
commits-20090109 at openlayers.org
Fri Feb 25 08:36:34 EST 2011
Author: ahocevar
Date: 2011-02-25 05:36:33 -0800 (Fri, 25 Feb 2011)
New Revision: 11492
Modified:
sandbox/ahocevar/layercontainer/lib/OpenLayers/Map.js
sandbox/ahocevar/layercontainer/tests/Layer/Google/v3.html
Log:
re-adding custom precision
Modified: sandbox/ahocevar/layercontainer/lib/OpenLayers/Map.js
===================================================================
--- sandbox/ahocevar/layercontainer/lib/OpenLayers/Map.js 2011-02-25 13:34:59 UTC (rev 11491)
+++ sandbox/ahocevar/layercontainer/lib/OpenLayers/Map.js 2011-02-25 13:36:33 UTC (rev 11492)
@@ -221,7 +221,7 @@
* {<OpenLayers.LonLat>} The current center of the map
*/
center: null,
-
+
/**
* Property: resolution
* {Float} The resolution of the map.
Modified: sandbox/ahocevar/layercontainer/tests/Layer/Google/v3.html
===================================================================
--- sandbox/ahocevar/layercontainer/tests/Layer/Google/v3.html 2011-02-25 13:34:59 UTC (rev 11491)
+++ sandbox/ahocevar/layercontainer/tests/Layer/Google/v3.html 2011-02-25 13:36:33 UTC (rev 11492)
@@ -266,6 +266,12 @@
t.plan(8);
+ var origPrecision = OpenLayers.Util.DEFAULT_PRECISION;
+ // GMaps v3 seems to use a default precision of 13, which is lower
+ // than what we use in OpenLayers.
+ // See http://trac.osgeo.org/openlayers/ticket/3059
+ OpenLayers.Util.DEFAULT_PRECISION = 13;
+
var map = new OpenLayers.Map('map', {allOverlays: true});
var gmap = new OpenLayers.Layer.Google("Google Streets");
@@ -310,6 +316,7 @@
t.eq(center.lat, origin.lat, "y panning with Google invisible " + (-dx) + ", " + (-dy));
map.destroy();
+ OpenLayers.Util.DEFAULT_PRECISION = origPrecision;
}
function test_wrapDateLine(t) {
More information about the Commits
mailing list