mirror of
https://github.com/openseadragon/openseadragon.git
synced 2025-02-07 18:39:23 +03:00
Refactor to reflect the reviewer comments
See also: https://github.com/openseadragon/openseadragon/pull/807#discussion_r48447403
This commit is contained in:
parent
fb222d9fe9
commit
27c91204b6
@ -372,7 +372,7 @@ $.extend( $.Navigator.prototype, $.EventSource.prototype, $.Viewer.prototype, /*
|
|||||||
*/
|
*/
|
||||||
function onCanvasClick( event ) {
|
function onCanvasClick( event ) {
|
||||||
if ( event.quick && this.viewer.viewport ) {
|
if ( event.quick && this.viewer.viewport ) {
|
||||||
this.viewer.viewport.panTo( this.viewport.pointFromPixelNoRotate( event.position ).rotate( -this.viewer.viewport.degrees, this.viewer.viewport.getHomeBounds().getCenter() ) );
|
this.viewer.viewport.panTo(this.viewport.pointFromPixel(event.position));
|
||||||
this.viewer.viewport.applyConstraints();
|
this.viewer.viewport.applyConstraints();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user