Add projection parameter to ol.source.Tile#expireCache and #useTile
This is required to be able to determine which cache the xyz coordinates refer to (in case we have more caches).
This commit is contained in:
@@ -98,10 +98,14 @@ ol.source.Tile.prototype.canExpireCache = function() {
|
||||
|
||||
|
||||
/**
|
||||
* @param {ol.proj.Projection} projection
|
||||
* @param {Object.<string, ol.TileRange>} usedTiles Used tiles.
|
||||
*/
|
||||
ol.source.Tile.prototype.expireCache = function(usedTiles) {
|
||||
this.tileCache.expireCache(usedTiles);
|
||||
ol.source.Tile.prototype.expireCache = function(projection, usedTiles) {
|
||||
var tileCache = this.getTileCacheForProjection(projection);
|
||||
if (!goog.isNull(tileCache)) {
|
||||
tileCache.expireCache(usedTiles);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -267,6 +271,7 @@ ol.source.Tile.prototype.getTileCoordForTileUrlFunction =
|
||||
* @param {number} z Tile coordinate z.
|
||||
* @param {number} x Tile coordinate x.
|
||||
* @param {number} y Tile coordinate y.
|
||||
* @param {ol.proj.Projection} projection Projection.
|
||||
*/
|
||||
ol.source.Tile.prototype.useTile = ol.nullFunction;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user