[OpenLayers-Commits] r11593 - sandbox/crschmidt/ovi-mobile/examples

commits-20090109 at openlayers.org commits-20090109 at openlayers.org
Tue Mar 1 05:03:05 EST 2011


Author: crschmidt
Date: 2011-03-01 02:03:04 -0800 (Tue, 01 Mar 2011)
New Revision: 11593

Modified:
   sandbox/crschmidt/ovi-mobile/examples/ovi-base.js
   sandbox/crschmidt/ovi-mobile/examples/ovi-jq.js
Log:
Change layerswitcher, add more ovi layers.


Modified: sandbox/crschmidt/ovi-mobile/examples/ovi-base.js
===================================================================
--- sandbox/crschmidt/ovi-mobile/examples/ovi-base.js	2011-03-01 09:34:05 UTC (rev 11592)
+++ sandbox/crschmidt/ovi-mobile/examples/ovi-base.js	2011-03-01 10:03:04 UTC (rev 11593)
@@ -9,7 +9,7 @@
 
 var init = function () {
 
-    var vector = new OpenLayers.Layer.Vector("Vector Layer", {});
+    var vector = new OpenLayers.Layer.Vector("Vector Layer", {displayInLayerSwitcher: false});
 
     var geolocate = new OpenLayers.Control.Geolocate({
         id: 'locate-control',
@@ -25,7 +25,7 @@
         theme: null,
         projection: sm,
         units: "m",
-        numZoomLevels: 18,
+        numZoomLevels: 21,
         maxResolution: 156543.0339,
         maxExtent: new OpenLayers.Bounds(
             -20037508.34, -20037508.34, 20037508.34, 20037508.34
@@ -41,9 +41,19 @@
             geolocate
         ],
         layers: [
-            new OpenLayers.Layer.XYZ("Ovi Maps", "http://maptile.maps.svc.ovi.com/maptiler/maptile/newest/normal.day/${z}/${x}/${y}/256/png8", {
-                transitionEffect: 'resize', sphericalMercator: true
+            new OpenLayers.Layer.XYZ("Street", ["http://a.maptile.maps.svc.ovi.com/maptiler/maptile/newest/normal.day/${z}/${x}/${y}/256/png8",
+                                                "http://b.maptile.maps.svc.ovi.com/maptiler/maptile/newest/normal.day/${z}/${x}/${y}/256/png8"], {
+                transitionEffect: 'resize', sphericalMercator: true, numZoomLevels: 21
             }),
+            new OpenLayers.Layer.XYZ("Transit", ["http://c.maptile.maps.svc.ovi.com/maptiler/maptile/newest/normal.day.transit/${z}/${x}/${y}/256/png8",
+                                                "http://d.maptile.maps.svc.ovi.com/maptiler/maptile/newest/normal.day.transit/${z}/${x}/${y}/256/png8"], {
+                transitionEffect: 'resize', sphericalMercator: true, numZoomLevels: 21
+            }),
+            new OpenLayers.Layer.XYZ("Satellite", ["http://e.maptile.maps.svc.ovi.com/maptiler/maptile/newest/hybrid.day/${z}/${x}/${y}/256/png8",
+                                                   "http://f.maptile.maps.svc.ovi.com/maptiler/maptile/newest/hybrid.day/${z}/${x}/${y}/256/png8"],
+                {
+                transitionEffect: 'resize', sphericalMercator: true, numZoomLevels: 21
+            }),
             vector
         ],
         center: new OpenLayers.LonLat(0, 4000000),

Modified: sandbox/crschmidt/ovi-mobile/examples/ovi-jq.js
===================================================================
--- sandbox/crschmidt/ovi-mobile/examples/ovi-jq.js	2011-03-01 09:34:05 UTC (rev 11592)
+++ sandbox/crschmidt/ovi-mobile/examples/ovi-jq.js	2011-03-01 10:03:04 UTC (rev 11593)
@@ -51,7 +51,8 @@
             'fillOpacity': .8,
             'pointRadius': 10,
             'label': '${ordinal}'
-        })});
+        }),
+        'displayInLayerSwitcher': false});
     map.addLayer(searchLayer);
 /*    var sprintersLayer = new OpenLayers.Layer.Vector("Sprinters", {
         styleMap: new OpenLayers.StyleMap({
@@ -179,7 +180,7 @@
         addLayerToList(this);
     });
 
-    $('<li>', {
+    /*$('<li>', {
             "data-role": "list-divider",
             text: "Overlay Layers"
         })
@@ -187,11 +188,11 @@
     var overlayLayers = map.getLayersBy("isBaseLayer", false);
     $.each(overlayLayers, function() {
         addLayerToList(this);
-    });
+    });*/
     $('#layerslist').listview('refresh');
     
     map.events.register("addlayer", this, function(e) {
-        addLayerToList(e.layer);
+            addLayerToList(e.layer);
     });
 });
 



More information about the Commits mailing list