add removeLayer() function to Layers... implement it for EventPane so that it removes the extra 'pane' div when the layer is removed. (Closes #887)
git-svn-id: http://svn.openlayers.org/trunk/openlayers@4053 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
@@ -566,8 +566,9 @@ OpenLayers.Map = OpenLayers.Class({
|
||||
} else {
|
||||
this.layerContainerDiv.removeChild(layer.div);
|
||||
}
|
||||
layer.map = null;
|
||||
OpenLayers.Util.removeItem(this.layers, layer);
|
||||
layer.removeMap(this);
|
||||
layer.map = null;
|
||||
|
||||
// if we removed the base layer, need to set a new one
|
||||
if (setNewBaseLayer && (this.baseLayer == layer)) {
|
||||
|
||||
Reference in New Issue
Block a user