зеркало из https://github.com/mozilla/gecko-dev.git
really fixing #63992 this time. thank to hwaara for point out the
problem. sr=bienvenu
This commit is contained in:
Родитель
61c439155f
Коммит
a4dd44d696
|
@ -27,6 +27,8 @@ function onInit()
|
|||
{
|
||||
stringBundle = srGetStrBundle("chrome://messenger/locale/messenger.properties");
|
||||
initServerType();
|
||||
|
||||
setupBiffUI(false);
|
||||
}
|
||||
|
||||
function onPreInit(account, accountValues)
|
||||
|
@ -34,8 +36,6 @@ function onPreInit(account, accountValues)
|
|||
var type = parent.getAccountValue(account, accountValues, "server", "type");
|
||||
|
||||
hideShowControls(type);
|
||||
|
||||
setupBiffUI();
|
||||
}
|
||||
|
||||
|
||||
|
@ -178,7 +178,7 @@ function secureSelect() {
|
|||
document.getElementById("server.port").value = protocolInfo.getDefaultServerPort(false);
|
||||
}
|
||||
|
||||
function setupBiffUI()
|
||||
function setupBiffUI(fromOnCommand)
|
||||
{
|
||||
var parentCheckBox = document.getElementById('server.doBiff');
|
||||
var checkBox = document.getElementById('server.downloadOnBiff');
|
||||
|
@ -194,14 +194,20 @@ function setupBiffUI()
|
|||
checked = false;
|
||||
}
|
||||
|
||||
if (checked) {
|
||||
checkBox.setAttribute("disabled", "true");
|
||||
textField.setAttribute("disabled", "true");
|
||||
textLabel.setAttribute("disabled", "true");
|
||||
// if we are called from oncommand, reverse this, since the
|
||||
// checked value is what the checkbox was before we clicked on it
|
||||
if (fromOnCommand) {
|
||||
checked = !checked;
|
||||
}
|
||||
else {
|
||||
|
||||
if (checked) {
|
||||
checkBox.removeAttribute("disabled");
|
||||
textField.removeAttribute("disabled");
|
||||
textLabel.removeAttribute("disabled");
|
||||
}
|
||||
else {
|
||||
checkBox.setAttribute("disabled", "true");
|
||||
textField.setAttribute("disabled", "true");
|
||||
textLabel.setAttribute("disabled", "true");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -91,7 +91,7 @@ hwaara@chello.se
|
|||
-->
|
||||
<box orient="horizontal" autostretch="never">
|
||||
<checkbox wsm_persist="true" id="server.doBiff" value="&biffStart.label;"
|
||||
oncommand="setupBiffUI()"/>
|
||||
oncommand="setupBiffUI(true)"/>
|
||||
<textfield wsm_persist="true" id="server.biffMinutes" size="3"/>
|
||||
<text class="label" id="biffEnd" for="server.biffMinutes" value="&biffEnd.label;"/>
|
||||
</box>
|
||||
|
|
Загрузка…
Ссылка в новой задаче