X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/6d124f801224ee441dbb7e67b912b8689cab6dfb..e20bb507f122f73d18021bf93efe85fc2e189dfb:/app/assets/javascripts/leaflet.layers.js diff --git a/app/assets/javascripts/leaflet.layers.js b/app/assets/javascripts/leaflet.layers.js index d2928068d..9f2e50a6f 100644 --- a/app/assets/javascripts/leaflet.layers.js +++ b/app/assets/javascripts/leaflet.layers.js @@ -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));