Fixed overlay position in Firefox and Internet Explorer
authorAlexander Ebert <ebert@woltlab.com>
Fri, 10 May 2013 18:38:57 +0000 (20:38 +0200)
committerAlexander Ebert <ebert@woltlab.com>
Fri, 10 May 2013 18:38:57 +0000 (20:38 +0200)
wcfsetup/install/files/js/WCF.js

index 9b9d79f497fa42e4e2185c5713e4720d6d5c410d..7c1a4c90cc77335af622c44c7cf8079ddb6512d9 100755 (executable)
@@ -8305,13 +8305,10 @@ $.widget('ui.wcfDialog', {
                var $maximumHeight = $windowDimensions.height - $heightDifference - 120;
                this._content.css({ maxHeight: $maximumHeight + 'px' });
                
-               // re-caculate values if container height was previously limited
-               if ($maximumHeight < $contentDimensions.height) {
-                       $containerDimensions = this._container.getDimensions('outer');
-               }
+               this._determineOverflow();
                
                // calculate new dimensions
-               $contentDimensions = this._getContentDimensions($maximumHeight);
+               $containerDimensions = this._container.getDimensions('outer');
                
                // move container
                var $leftOffset = Math.round(($windowDimensions.width - $containerDimensions.width) / 2);
@@ -8335,8 +8332,6 @@ $.widget('ui.wcfDialog', {
                        width: 'auto'
                });
                
-               this._determineOverflow();
-               
                if (!this.isOpen()) {
                        // hide container again
                        this._container.hide();