Merge pull request #4594 from klokantech/tilequeue-reproj-jam
Fix for TileQueue gradually choking up when using raster reprojection
This commit is contained in:
@@ -322,7 +322,7 @@ ol.reproj.Tile.prototype.load = function() {
|
||||
});
|
||||
|
||||
if (leftToLoad === 0) {
|
||||
this.reproject_();
|
||||
goog.global.setTimeout(goog.bind(this.reproject_, this), 0);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
@@ -119,10 +119,10 @@ ol.TileQueue.prototype.loadMoreTiles = function(maxTotalLoading, maxNewLoads) {
|
||||
this.getCount() > 0) {
|
||||
tile = /** @type {ol.Tile} */ (this.dequeue()[0]);
|
||||
if (tile.getState() === ol.TileState.IDLE) {
|
||||
tile.load();
|
||||
this.tilesLoadingKeys_[tile.getKey()] = true;
|
||||
++this.tilesLoading_;
|
||||
++newLoads;
|
||||
tile.load();
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user