From 69bf069038da59207bb3b3fe1d51ba098208ef82 Mon Sep 17 00:00:00 2001 From: Rob Sanderson Date: Mon, 28 Jul 2014 12:17:45 -0700 Subject: [PATCH] navigator to request maxLevel tileSize --- src/navigator.js | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/src/navigator.js b/src/navigator.js index 2043a8f4..e04c6a60 100644 --- a/src/navigator.js +++ b/src/navigator.js @@ -298,12 +298,9 @@ $.extend( $.Navigator.prototype, $.EventSource.prototype, $.Viewer.prototype, /* open: function( source ) { this.updateSize(); var containerSize = this.viewer.viewport.containerSize.times( this.sizeRatio ); - if( source.tileSize > containerSize.x || - source.tileSize > containerSize.y ){ - this.minPixelRatio = Math.min( - containerSize.x, - containerSize.y - ) / source.tileSize; + var ts = source.getTileSize(source.maxLevel); + if ( ts > containerSize.x || ts > containerSize.y ) { + this.minPixelRatio = Math.min( containerSize.x, containerSize.y ) / ts; } else { this.minPixelRatio = this.viewer.minPixelRatio; }