getLayer by id.
This commit is contained in:
parent
6ea5984dc6
commit
df2ef42fe4
@ -88,8 +88,13 @@ L.LayerGroup = L.Class.extend({
|
|||||||
return this;
|
return this;
|
||||||
},
|
},
|
||||||
|
|
||||||
|
getLayer: function (id) {
|
||||||
|
return this._layers[id];
|
||||||
|
},
|
||||||
|
|
||||||
getLayers: function () {
|
getLayers: function () {
|
||||||
var layers = [];
|
var layers = [];
|
||||||
|
|
||||||
for (var i in this._layers) {
|
for (var i in this._layers) {
|
||||||
layers.push(this._layers[i]);
|
layers.push(this._layers[i]);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user