Move scale/resolution configuration to the base layers so that

people dragging in our customer layers don't need to worry about
setting the magic numbers.
This commit is contained in:
Tom Hughes 2007-12-06 14:18:30 +00:00
parent 3ed64ceb54
commit 7ee377352e
2 changed files with 24 additions and 22 deletions

View file

@ -3,11 +3,7 @@ var markers;
var popup;
function createMap(divName) {
map = new OpenLayers.Map(divName,
{ maxExtent: new OpenLayers.Bounds(-20037508,-20037508,20037508,20037508),
maxResolution: 156543,
units: 'm',
projection: "EPSG:41001" });
map = new OpenLayers.Map(divName);
var mapnik = new OpenLayers.Layer.OSM.Mapnik("Mapnik", { displayOutsideMaxExtent: true });
map.addLayer(mapnik);