mirror of
https://github.com/openseadragon/openseadragon.git
synced 2024-11-21 20:56:09 +03:00
Resolved suggestions
- Avoid useless parameters _navigatorRotate since it already exists within the navigator; - Automatically rotate the image in the demo page.
This commit is contained in:
parent
d897e5454f
commit
7fb5744495
@ -224,8 +224,6 @@ $.Navigator = function( options ){
|
||||
this.displayRegionContainer.appendChild(this.displayRegion);
|
||||
this.element.getElementsByTagName('div')[0].appendChild(this.displayRegionContainer);
|
||||
|
||||
this._navigatorRotate = options.navigatorRotate;
|
||||
|
||||
function rotate(degrees, immediately) {
|
||||
_setTransformRotate(_this.displayRegionContainer, degrees);
|
||||
_setTransformRotate(_this.displayRegion, -degrees);
|
||||
@ -399,7 +397,7 @@ $.extend( $.Navigator.prototype, $.EventSource.prototype, $.Viewer.prototype, /*
|
||||
bottomright = this.viewport.pixelFromPointNoRotate(bounds.getBottomRight(), false)
|
||||
.minus( this.totalBorderWidths );
|
||||
|
||||
if (!this._navigatorRotate) {
|
||||
if (!this.navigatorRotate) {
|
||||
var degrees = viewport.getRotation(true);
|
||||
_setTransformRotate(this.displayRegion, -degrees);
|
||||
}
|
||||
|
@ -20,7 +20,6 @@
|
||||
</div>
|
||||
<div id="contentDiv" class="openseadragon1"></div>
|
||||
<script type="text/javascript">
|
||||
|
||||
var viewer = OpenSeadragon({
|
||||
// debugMode: true,
|
||||
id: "contentDiv",
|
||||
@ -29,6 +28,7 @@
|
||||
showNavigator: true,
|
||||
navigatorRotate: false
|
||||
});
|
||||
viewer.viewport.setRotation(45)
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
|
Loading…
Reference in New Issue
Block a user