From 418e21e9f4f6d9116c752ab1d5ae38c116c0c56b Mon Sep 17 00:00:00 2001 From: Larissa Smith Date: Mon, 14 Sep 2015 16:57:50 -0600 Subject: [PATCH] Fix for issue with tiledImages loading tiles at every level instead of just the best level: using && instead of || means the tiledImage's longest side is used for comparison instead of the shortest side. --- src/tilesource.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/tilesource.js b/src/tilesource.js index 65841d25..b13df91d 100644 --- a/src/tilesource.js +++ b/src/tilesource.js @@ -332,7 +332,7 @@ $.TileSource.prototype = /** @lends OpenSeadragon.TileSource.prototype */{ Math.floor( rect.y / this.getTileHeight(i) ) ); - if( tiles.x + 1 >= tilesPerSide.x || tiles.y + 1 >= tilesPerSide.y ){ + if( tiles.x + 1 >= tilesPerSide.x && tiles.y + 1 >= tilesPerSide.y ){ break; } }