diff --git a/browser/components/preferences/tabs.xul b/browser/components/preferences/tabs.xul index 6f4fb385a2c..5b8eff3f5e3 100644 --- a/browser/components/preferences/tabs.xul +++ b/browser/components/preferences/tabs.xul @@ -49,7 +49,7 @@ - + @@ -75,8 +75,8 @@ - + targetHeight) { + var verticalPadding = parseInt(window.getComputedStyle(aPaneElement, "").paddingTop); + verticalPadding += parseInt(window.getComputedStyle(aPaneElement, "").paddingBottom); + if (aPaneElement.contentHeight > targetHeight - verticalPadding) { // To workaround the bottom border of a groupbox from being // cutoff an hbox with a class of bottomBox may enclose it. // This needs to include its padding to resize properly. @@ -760,10 +768,14 @@ var bottomBox = aPaneElement.getElementsByAttribute("class", "bottomBox")[0]; if (bottomBox) bottomPadding = parseInt(window.getComputedStyle(bottomBox, "").paddingBottom); - window.innerHeight += bottomPadding + aPaneElement.contentHeight - targetHeight; + window.innerHeight += bottomPadding + verticalPadding + aPaneElement.contentHeight - targetHeight; } + + // XXX rstrong - extend the contents of the prefpane to + // prevent elements from being cutoff (see bug 349098). + if (aPaneElement.contentHeight + verticalPadding < targetHeight) + aPaneElement._content.style.height = targetHeight - verticalPadding + "px"; } - this._initialized = true; } break; }