From e03605929bcd7fe864c0b0c38c4ec8c80f865c39 Mon Sep 17 00:00:00 2001 From: Christopher Schmidt Date: Sun, 20 Apr 2008 13:16:29 +0000 Subject: [PATCH] Fix offset when laying in vectors on top of the OSM tiles. --- public/javascripts/map.js | 2 +- public/openlayers/OpenStreetMap.js | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/public/javascripts/map.js b/public/javascripts/map.js index 0dadbb9d3..bc2e90863 100644 --- a/public/javascripts/map.js +++ b/public/javascripts/map.js @@ -19,7 +19,7 @@ function createMap(divName, options) { new OpenLayers.Control.ScaleLine() ], units: "m", - maxResolution: 156543, + maxResolution: 156543.0339, numZoomLevels: 20 }); diff --git a/public/openlayers/OpenStreetMap.js b/public/openlayers/OpenStreetMap.js index c2acf2e0c..d6bc397d1 100644 --- a/public/openlayers/OpenStreetMap.js +++ b/public/openlayers/OpenStreetMap.js @@ -48,8 +48,8 @@ OpenLayers.Layer.OSM = OpenLayers.Class(OpenLayers.Layer.TMS, { initialize: function(name, url, options) { options = OpenLayers.Util.extend({ attribution: "Data by OpenStreetMap", - maxExtent: new OpenLayers.Bounds(-20037508,-20037508,20037508,20037508), - maxResolution: 156543, + maxExtent: new OpenLayers.Bounds(-20037508.34,-20037508.34,20037508.34,20037508.34), + maxResolution: 156543.0339, units: "m", projection: "EPSG:900913", transitionEffect: "resize" -- 2.39.5