projects
/
GitHub
/
WoltLab
/
WCF.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b065e78
)
Fixed overflow calculation for dialog overlays
author
Alexander Ebert
<ebert@woltlab.com>
Mon, 29 Jul 2013 13:06:44 +0000
(15:06 +0200)
committer
Alexander Ebert
<ebert@woltlab.com>
Mon, 29 Jul 2013 13:06:44 +0000
(15:06 +0200)
wcfsetup/install/files/js/WCF.js
patch
|
blob
|
blame
|
history
diff --git
a/wcfsetup/install/files/js/WCF.js
b/wcfsetup/install/files/js/WCF.js
index 8fe0c8f2ed47116ff6277b9d27af201bc1fd020d..0742818ef8aa4a085b2855031ce5ad4220a68b75 100755
(executable)
--- a/
wcfsetup/install/files/js/WCF.js
+++ b/
wcfsetup/install/files/js/WCF.js
@@
-8647,6
+8647,18
@@
$.widget('ui.wcfDialog', {
this._content.css('overflow', $overflow);
this._content.css('maxHeight', $maxHeight);
+
+ if ($overflow === 'visible') {
+ // content may already overflow, even though the overall height is still below the threshold
+ var $contentHeight = 0;
+ this._content.children().each(function(index, child) {
+ $contentHeight += $(child).outerHeight();
+ });
+
+ if (this._content.height() < $contentHeight) {
+ this._content.css('overflow', 'auto');
+ }
+ }
},
/**