[OpenLayers-Commits] r11907 - trunk/openlayers/examples

commits-20090109 at openlayers.org commits-20090109 at openlayers.org
Thu Apr 21 18:44:32 EDT 2011


Author: tschaub
Date: 2011-04-21 15:44:31 -0700 (Thu, 21 Apr 2011)
New Revision: 11907

Modified:
   trunk/openlayers/examples/wfs-snap-split.html
Log:
Giving the restricted extent some width.

Modified: trunk/openlayers/examples/wfs-snap-split.html
===================================================================
--- trunk/openlayers/examples/wfs-snap-split.html	2011-04-21 22:15:52 UTC (rev 11906)
+++ trunk/openlayers/examples/wfs-snap-split.html	2011-04-21 22:44:31 UTC (rev 11907)
@@ -96,17 +96,16 @@
         });
 
         function init() {
-            OpenLayers.ProxyHost= "proxy.cgi?url=";
-            map = new OpenLayers.Map('map', {
-                maxResolution: 156543.03390625,
+            OpenLayers.ProxyHost = "proxy.cgi?url=";
+            map = new OpenLayers.Map({
+                div: "map",
+                maxResolution: 156543.0339,
+                maxExtent: new OpenLayers.Bounds(-20037508, -20037508, 20037508, 20037508),
                 restrictedExtent: new OpenLayers.Bounds(
-                    -11560239, 5541115, -11560239, 5542338
+                    -11563906, 5540550, -11559015, 5542996
                 ),
-                maxExtent: new OpenLayers.Bounds(
-                    -2.003750834E7,-2.003750834E7,
-                    2.003750834E7,2.003750834E7
-                ),
                 projection: new OpenLayers.Projection("EPSG:900913"),
+                units: "m",
                 controls: [
                     new OpenLayers.Control.PanZoom()
                 ]
@@ -240,7 +239,7 @@
             
             panel.defaultControl = panel.controls[0];
             map.addControl(panel);
-            map.zoomTo(15);
+            map.setCenter(new OpenLayers.LonLat(-11561460.5, 5541773), 15);
         }
 
         function flashFeatures(features, index) {



More information about the Commits mailing list