]> dev.renevier.net Git - syj.git/blobdiff - public/js/syj.js
revert: add mapquest layer
[syj.git] / public / js / syj.js
index 78d7606afe2276634e0db2b6227bb40cf591f22e..fbe3f737efcc06d9ff0eef3a091e0b03aa59c554 100644 (file)
@@ -288,7 +288,11 @@ var SYJView = {
             theme: null
         });
 
-        baseLayer = new OpenLayers.Layer.OSM("OSM", null, { wrapDateLine: true , attribution: SyjStrings.osmAttribution });
+        baseLayer = new OpenLayers.Layer.OSM("OSM", [
+                'http://a.tile.openstreetmap.org/${z}/${x}/${y}.png',
+                'http://b.tile.openstreetmap.org/${z}/${x}/${y}.png',
+                'http://c.tile.openstreetmap.org/${z}/${x}/${y}.png'],
+                { wrapDateLine: true , attribution: SyjStrings.osmAttribution });
 
         layerOptions = {format:     OpenLayers.Format.WKT,
                         projection: WGS84,
@@ -446,13 +450,6 @@ var SYJView = {
         } else {
             this.map.setCenter(center, zoom);
         }
-        this.resizeMap();
-    },
-
-    resizeMap: function() {
-        var map = $('map');
-        map.style.width = map.offsetWidth.toString() + 'px';
-        map.style.height = map.offsetHeight.toString() + 'px';
     },
 
     observer: function(evt) {
@@ -1289,7 +1286,3 @@ window.onbeforeunload = function() {
         return undefined;
     }
 };
-
-window.onresize = function() {
-    SYJView.resizeMap();
-};