Add optional destination extent in ol.source.Vector#getExtent

This commit is contained in:
Frederic Junod
2017-04-04 13:53:29 +02:00
parent f7c392342e
commit 22ed575325

View File

@@ -610,11 +610,12 @@ ol.source.Vector.prototype.getClosestFeatureToCoordinate = function(coordinate,
*
* This method is not available when the source is configured with
* `useSpatialIndex` set to `false`.
* @param {ol.Extent=} opt_extent Destination extent.
* @return {!ol.Extent} Extent.
* @api
*/
ol.source.Vector.prototype.getExtent = function() {
return this.featuresRtree_.getExtent();
ol.source.Vector.prototype.getExtent = function(opt_extent) {
return this.featuresRtree_.getExtent(opt_extent);
};