Fix Graticule use of incorrect min/maxLon values

Appears to have just been a typeo, using the minLon_, maxLon_ member variables rather than the function parameters provided.

This was creating very wide lines of parallel which were sometimes very slow in Chrome.
This commit is contained in:
Greg Gianforcaro
2017-07-17 17:53:39 -04:00
parent 89ec2dacad
commit 704cd03d96

View File

@@ -519,7 +519,7 @@ ol.Graticule.prototype.getMeridians = function() {
ol.Graticule.prototype.getParallel_ = function(lat, minLon, maxLon,
squaredTolerance, index) {
var flatCoordinates = ol.geom.flat.geodesic.parallel(lat,
this.minLon_, this.maxLon_, this.projection_, squaredTolerance);
minLon, maxLon, this.projection_, squaredTolerance);
var lineString = this.parallels_[index] !== undefined ?
this.parallels_[index] : new ol.geom.LineString(null);
lineString.setFlatCoordinates(ol.geom.GeometryLayout.XY, flatCoordinates);