]> git.openstreetmap.org Git - rails.git/blobdiff - app/assets/javascripts/leaflet.layers.js
Update bundle
[rails.git] / app / assets / javascripts / leaflet.layers.js
index d2928068d4d6a1ec1a754e0a081f75b90f4cf356..c294f13ef2ef749065a4753e3a0e5f13a369a03b 100644 (file)
@@ -50,7 +50,7 @@ L.OSM.layers = function(options) {
 
       map.whenReady(function() {
         var miniMap = L.map(div[0], {attributionControl: false, zoomControl: false})
-          .addLayer(new layer.constructor());
+          .addLayer(new layer.constructor({ apikey: layer.options.apikey }));
 
         miniMap.dragging.disable();
         miniMap.touchZoom.disable();
@@ -101,6 +101,8 @@ L.OSM.layers = function(options) {
         map.fire('baselayerchange', {layer: layer});
       });
 
+      item.on('dblclick', toggle);
+
       map.on('layeradd layerremove', function() {
         item.toggleClass('active', map.hasLayer(layer));
         input.prop('checked', map.hasLayer(layer));