Inform iconLayers when we change current tilelayer
When an editor change the background layer from our own selector, we need to inform iconLayers, so it can update its list and order accordingly
This commit is contained in:
parent
426297df4f
commit
629a049eba
1 changed files with 2 additions and 0 deletions
|
@ -1208,7 +1208,9 @@ L.U.TileLayerControl = L.Control.IconLayers.extend({
|
|||
}
|
||||
const maxShown = 10
|
||||
L.Control.IconLayers.prototype.setLayers.call(this, layers.slice(0, maxShown))
|
||||
if (this.map.selected_tilelayer) this.setActiveLayer(this.map.selected_tilelayer)
|
||||
},
|
||||
|
||||
})
|
||||
|
||||
/* Used in edit mode to define the default tilelayer */
|
||||
|
|
Loading…
Reference in a new issue