mirror of
https://github.com/stylersnico/librenms.git
synced 2026-08-03 00:11:49 +02:00
When adding layers, don't add them to the map unless they are in the visible bounds. Fixes #69
This commit is contained in:
@@ -88,10 +88,12 @@ L.MarkerClusterGroup = L.FeatureGroup.extend({
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (this.options.animateAddingMarkers) {
|
if (this._currentShownBounds.contains(visibleLayer.getLatLng())) {
|
||||||
this._animationAddLayer(layer, visibleLayer);
|
if (this.options.animateAddingMarkers) {
|
||||||
} else {
|
this._animationAddLayer(layer, visibleLayer);
|
||||||
this._animationAddLayerNonAnimated(layer, visibleLayer);
|
} else {
|
||||||
|
this._animationAddLayerNonAnimated(layer, visibleLayer);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
return this;
|
return this;
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user