Merge pull request #1037 from fredj/perf

ol.TileCoord.getKeyZXY optimization
This commit is contained in:
Frédéric Junod
2013-09-18 09:16:28 -07:00
2 changed files with 2 additions and 4 deletions
+1 -3
View File
@@ -111,9 +111,7 @@ ol.source.Tile.prototype.findLoadedTiles = function(loadedTilesByZ,
* @return {string} Key. * @return {string} Key.
* @protected * @protected
*/ */
ol.source.Tile.prototype.getKeyZXY = function(z, x, y) { ol.source.Tile.prototype.getKeyZXY = ol.TileCoord.getKeyZXY;
return ol.TileCoord.getKeyZXY(z, x, y);
};
/** /**
+1 -1
View File
@@ -109,7 +109,7 @@ ol.TileCoord.createOrUpdate = function(z, x, y, tileCoord) {
* @return {string} Key. * @return {string} Key.
*/ */
ol.TileCoord.getKeyZXY = function(z, x, y) { ol.TileCoord.getKeyZXY = function(z, x, y) {
return [z, x, y].join('/'); return z + '/' + x + '/' + y;
}; };