mirror of
https://github.com/openseadragon/openseadragon.git
synced 2024-11-21 20:56:09 +03:00
Fixed: More meaning full variable and help text, innerStyle not outer
This commit is contained in:
parent
396fcb33a5
commit
2c5d2eb7c6
@ -230,8 +230,10 @@
|
|||||||
* @property {Boolean} [flipped=false]
|
* @property {Boolean} [flipped=false]
|
||||||
* Initial flip state.
|
* Initial flip state.
|
||||||
*
|
*
|
||||||
* @property {Boolean} [overlayContentFlipped=false]
|
* @property {Boolean} [overlayFlipReversal=true]
|
||||||
* Initial overlay content flip state.
|
* When the viewport is flipped (by pressing 'f'), the overlay is flipped using ScaleX.
|
||||||
|
* Normally, this setting (default true) keeps the overlay's content readable by flipping it back.
|
||||||
|
* To make the content flip with the overlay, set overlayFlipReversal to false.
|
||||||
*
|
*
|
||||||
* @property {Number} [minZoomLevel=null]
|
* @property {Number} [minZoomLevel=null]
|
||||||
*
|
*
|
||||||
@ -1340,7 +1342,7 @@ function OpenSeadragon( options ){
|
|||||||
|
|
||||||
// INITIAL FLIP STATE
|
// INITIAL FLIP STATE
|
||||||
flipped: false,
|
flipped: false,
|
||||||
overlayContentFlipped: false,
|
overlayFlipReversal: true,
|
||||||
|
|
||||||
// APPEARANCE
|
// APPEARANCE
|
||||||
opacity: 1,
|
opacity: 1,
|
||||||
|
@ -270,8 +270,8 @@
|
|||||||
this.onDraw(position, size, this.element);
|
this.onDraw(position, size, this.element);
|
||||||
} else {
|
} else {
|
||||||
var style = this.style;
|
var style = this.style;
|
||||||
var outerElement = element.firstChild;
|
var innerElement = element.firstChild;
|
||||||
var outerStyle = outerElement.style;
|
var innerStyle = innerElement.style;
|
||||||
style.left = position.x + "px";
|
style.left = position.x + "px";
|
||||||
style.top = position.y + "px";
|
style.top = position.y + "px";
|
||||||
if (this.width !== null) {
|
if (this.width !== null) {
|
||||||
@ -286,19 +286,19 @@
|
|||||||
'transform');
|
'transform');
|
||||||
if (transformOriginProp && transformProp) {
|
if (transformOriginProp && transformProp) {
|
||||||
if (rotate && !viewport.flipped) {
|
if (rotate && !viewport.flipped) {
|
||||||
outerStyle[transformProp] = "";
|
innerStyle[transformProp] = "";
|
||||||
style[transformOriginProp] = this._getTransformOrigin();
|
style[transformOriginProp] = this._getTransformOrigin();
|
||||||
style[transformProp] = "rotate(" + rotate + "deg)";
|
style[transformProp] = "rotate(" + rotate + "deg)";
|
||||||
} else if (!rotate && viewport.flipped) {
|
} else if (!rotate && viewport.flipped) {
|
||||||
outerStyle[transformProp] = outerScale;
|
innerStyle[transformProp] = outerScale;
|
||||||
style[transformOriginProp] = this._getTransformOrigin();
|
style[transformOriginProp] = this._getTransformOrigin();
|
||||||
style[transformProp] = scale;
|
style[transformProp] = scale;
|
||||||
} else if (rotate && viewport.flipped){
|
} else if (rotate && viewport.flipped){
|
||||||
outerStyle[transformProp] = outerScale;
|
innerStyle[transformProp] = outerScale;
|
||||||
style[transformOriginProp] = this._getTransformOrigin();
|
style[transformOriginProp] = this._getTransformOrigin();
|
||||||
style[transformProp] = "rotate(" + rotate + "deg)" + scale;
|
style[transformProp] = "rotate(" + rotate + "deg)" + scale;
|
||||||
} else {
|
} else {
|
||||||
outerStyle[transformProp] = "";
|
innerStyle[transformProp] = "";
|
||||||
style[transformOriginProp] = "";
|
style[transformOriginProp] = "";
|
||||||
style[transformProp] = "";
|
style[transformProp] = "";
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user