Permalink
Browse files

Accordion: Don't include the height of absolute/fixed positioned sibl…

…ings when calculating size for heightStyle: fill.
  • Loading branch information...
scottgonzalez committed Dec 19, 2010
1 parent 75b94a1 commit 32945202da1854a1b603db4994a263f4f789d398
Showing with 7 additions and 1 deletion.
  1. +7 −1 ui/jquery.ui.accordion.js
@@ -264,7 +264,13 @@ $.widget( "ui.accordion", {
}
maxHeight = this.element.parent().height();
this.element.siblings( ":visible" ).each(function() {
- maxHeight -= $( this ).outerHeight( true );
+ var elem = $( this ),
+ position = elem.css( "position" );
+
+ if ( position === "absolute" || position === "fixed" ) {
+ return;
+ }
+ maxHeight -= elem.outerHeight( true );
});
if ($.browser.msie) {
this.element.parent().css( "overflow", defOverflow );

0 comments on commit 3294520

Please sign in to comment.