From: John Firebaugh Date: Mon, 1 Jul 2013 19:57:06 +0000 (-0400) Subject: Fix export tab bugs X-Git-Tag: live~5402^2~16 X-Git-Url: https://git.openstreetmap.org./rails.git/commitdiff_plain/ad10390663f5c27d4ac9eea1ff35a5a6e2ae4622 Fix export tab bugs --- diff --git a/app/assets/javascripts/index/export.js b/app/assets/javascripts/index/export.js index 1f624f125..417dfabd3 100644 --- a/app/assets/javascripts/index/export.js +++ b/app/assets/javascripts/index/export.js @@ -203,7 +203,7 @@ function initializeExport(map) { var zoom = map.getBoundsZoom(bounds); - var layers = getMapLayers(map); + var layers = map.getLayersCode(); var text = I18n.t('export.start_rjs.view_larger_map'); var escaped = []; diff --git a/app/assets/javascripts/leaflet.layers.js b/app/assets/javascripts/leaflet.layers.js index 242f76285..8653a0921 100644 --- a/app/assets/javascripts/leaflet.layers.js +++ b/app/assets/javascripts/leaflet.layers.js @@ -92,6 +92,7 @@ L.OSM.layers = function(options) { map.removeLayer(other); } }); + map.fire('baselayerchange', {layer: layer}); }); map.on('layeradd layerremove', function() {