mirror of
https://github.com/openseadragon/openseadragon.git
synced 2024-11-25 14:46:10 +03:00
Use style attributes when storing the previous elment size instead of the literal size of the element #220
This commit is contained in:
parent
75ddd299e4
commit
6d6cc363b4
@ -666,7 +666,8 @@ $.extend( $.Viewer.prototype, $.EventHandler.prototype, $.ControlDock.prototype,
|
||||
this.previousBody = [];
|
||||
THIS[ this.hash ].prevElementParent = this.element.parentNode;
|
||||
THIS[ this.hash ].prevNextSibling = this.element.nextSibling;
|
||||
THIS[ this.hash ].prevElementSize = $.getElementSize( this.element );
|
||||
THIS[ this.hash ].prevElementWidth = this.element.style.width;
|
||||
THIS[ this.hash ].prevElementHeight = this.element.style.height;
|
||||
nodes = body.childNodes.length;
|
||||
for ( i = 0; i < nodes; i ++ ){
|
||||
this.previousBody.push( body.childNodes[ 0 ] );
|
||||
@ -783,8 +784,8 @@ $.extend( $.Viewer.prototype, $.EventHandler.prototype, $.ControlDock.prototype,
|
||||
//this.container.style.top = 'auto';
|
||||
}
|
||||
|
||||
this.element.style.height = THIS[ this.hash ].prevElementSize.y + 'px';
|
||||
this.element.style.width = THIS[ this.hash ].prevElementSize.x + 'px';
|
||||
this.element.style.width = THIS[ this.hash ].prevElementWidth;
|
||||
this.element.style.height = THIS[ this.hash ].prevElementHeight;
|
||||
|
||||
THIS[ this.hash ].fullPage = false;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user