From de2fcb1b745e8547ada96b601fe646ef968f1719 Mon Sep 17 00:00:00 2001 From: Ian Gilman Date: Thu, 11 May 2017 10:19:43 -0700 Subject: [PATCH] Changelog for #1184 --- changelog.txt | 1 + src/viewport.js | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/changelog.txt b/changelog.txt index d8f2e28c..32b50acb 100644 --- a/changelog.txt +++ b/changelog.txt @@ -36,6 +36,7 @@ OPENSEADRAGON CHANGELOG * Fixed: the reference strip would leak memory when opening new sets of images (#1175) * You can now load tiles via AJAX and custom AJAX request headers (#1055) * Added fix for supporting weird filenames that look like JSONs (#1189) +* Fixed: zoomTo/zoomBy ignore refPoint if immediately is true (#1184) 2.2.1: diff --git a/src/viewport.js b/src/viewport.js index a93a4922..55851dc4 100644 --- a/src/viewport.js +++ b/src/viewport.js @@ -806,6 +806,7 @@ $.Viewport.prototype = { * @fires OpenSeadragon.Viewer.event:zoom */ zoomTo: function(zoom, refPoint, immediately) { + var _this = this; this.zoomPoint = refPoint instanceof $.Point && !isNaN(refPoint.x) && @@ -814,7 +815,6 @@ $.Viewport.prototype = { null; if (immediately) { - var _this = this; this._adjustCenterSpringsForZoomPoint(function() { _this.zoomSpring.resetTo(zoom); });