Back out c6aca5f18fdf (bug 1044597) for test failures

CLOSED TREE
This commit is contained in:
Phil Ringnalda 2015-02-08 21:29:33 -08:00
Родитель c833ea2dcb
Коммит d051edbe20
1 изменённых файлов: 3 добавлений и 12 удалений

Просмотреть файл

@ -92,8 +92,6 @@ let gSubDialog = {
// Clear the sizing attributes
this._box.removeAttribute("width");
this._box.removeAttribute("height");
this._box.style.removeProperty("min-height");
this._box.style.removeProperty("min-width");
setTimeout(() => {
// Unload the dialog after the event listeners run so that the load of about:blank isn't
@ -148,17 +146,10 @@ let gSubDialog = {
// padding-bottom doesn't seem to be included in the scrollHeight of the document element in XUL
// so add it ourselves.
let frameVerticalPadding = 2 * parseFloat(this._frame.contentWindow.getComputedStyle(docEl).paddingTop);
let frameHorizontalPadding = 2 * parseFloat(this._frame.contentWindow.getComputedStyle(docEl).paddingLeft);
let frameWidth = parseFloat(docEl.style.width) || docEl.scrollWidth;
let frameHeight = parseFloat(docEl.style.height) || (docEl.scrollHeight + frameVerticalPadding);
let boxVerticalBorder = 2 * parseFloat(getComputedStyle(this._box).borderTopWidth);
let boxHorizontalBorder = 2 * parseFloat(getComputedStyle(this._box).borderLeftWidth);
let paddingBottom = parseFloat(this._frame.contentWindow.getComputedStyle(docEl).paddingBottom);
this._frame.style.width = frameWidth + "px";
this._frame.style.height = frameHeight + "px";
this._box.style.minHeight = (boxVerticalBorder + this._box.clientHeight) + "px";
this._box.style.minWidth = (boxHorizontalBorder + frameHorizontalPadding + this._box.clientWidth) + "px";
this._frame.style.width = docEl.style.width || docEl.scrollWidth + "px";
this._frame.style.height = docEl.style.height || (docEl.scrollHeight + paddingBottom) + "px";
this._overlay.style.visibility = "visible";
this._frame.focus();