X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/6d124f801224ee441dbb7e67b912b8689cab6dfb..6cc4f4506b9a6612f57dd33d79e933d181a02713:/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));