Bug 255572: 'Restore Default' in customize toolbars window should restore display mode. r=ben@mozilla.org

This commit is contained in:
steffen.wilberg%web.de 2004-10-05 10:45:58 +00:00
parent 8df171f28e
commit e1e1c25bb8

View File

@ -22,7 +22,7 @@
# Joe Hewitt (hewitt@netscape.com)
const kRowMax = 4;
const kWindowWidth = 600;
const kWindowWidth = 635;
const kWindowHeight = 400;
const kAnimateIncrement = 50;
const kAnimateSteps = kWindowHeight / kAnimateIncrement - 1;
@ -554,6 +554,12 @@ function restoreDefaultSet()
toolbar = toolbar.nextSibling;
}
// Restore the default icon size (large) and mode (icons only).
updateIconSize(false);
document.getElementById("smallicons").checked = false;
updateToolbarMode("icons");
document.getElementById("modelist").value = "icons";
// Remove all of the customized toolbars.
var child = gToolbox.lastChild;
while (child) {
@ -608,14 +614,7 @@ function updateToolbarMode(aModeValue)
}
var iconSizeCheckbox = document.getElementById("smallicons");
if (aModeValue == "text") {
iconSizeCheckbox.disabled = true;
iconSizeCheckbox.checked = false;
}
else {
iconSizeCheckbox.disabled = false;
iconSizeCheckbox.checked = gToolboxIconSize;
}
iconSizeCheckbox.disabled = aModeValue == "text";
repositionDialog();
}