b=110195 Master passwords steals focus in prefs
r=kaie sr=alecf git-svn-id: svn://10.0.0.236/trunk@122249 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
@@ -63,10 +63,10 @@ function onMasterPasswordLoad()
|
||||
var timeoutField = document.getElementById("passwordTimeout");
|
||||
timeoutField.setAttribute("value", timeout);
|
||||
|
||||
changePasswordSettings();
|
||||
changePasswordSettings(false);
|
||||
}
|
||||
|
||||
function changePasswordSettings()
|
||||
function changePasswordSettings(setFocus)
|
||||
{
|
||||
var askTimes = 0;
|
||||
var timeout = internal_token.getAskPasswordTimeout();
|
||||
@@ -83,7 +83,9 @@ function changePasswordSettings()
|
||||
break;
|
||||
case "2":
|
||||
timeoutField.removeAttribute("disabled");
|
||||
timeoutField.focus();
|
||||
if ( setFocus ) {
|
||||
timeoutField.focus();
|
||||
}
|
||||
timeout = timeoutField.value;
|
||||
var re = new RegExp("^[0-9]+$");
|
||||
if (!re.test(timeout)) {
|
||||
|
||||
@@ -75,16 +75,16 @@
|
||||
<!-- note that these values are different than what NSS uses, which
|
||||
are (0, -1, 1) respectively -->
|
||||
<radio value="0" label="&managepassword.askfirsttime;" id="askFirstTime"
|
||||
style="margin: 0px;" oncommand="changePasswordSettings();"/>
|
||||
style="margin: 0px;" oncommand="changePasswordSettings(false);"/>
|
||||
<radio value="1" label="&managepassword.askeverytime;" id="askEveryTime"
|
||||
style="margin: 0px;" oncommand="changePasswordSettings();"/>
|
||||
style="margin: 0px;" oncommand="changePasswordSettings(false);"/>
|
||||
<hbox align="center">
|
||||
<radio value="2" label="&managepassword.asktimeout;" id="askTimeout"
|
||||
style="margin: 0px;" oncommand="changePasswordSettings();"/>
|
||||
style="margin: 0px;" oncommand="changePasswordSettings(true);"/>
|
||||
<textbox id="passwordTimeout" size="4"
|
||||
preftype="int"
|
||||
prefstring="security.password_lifetime"
|
||||
oninput="changePasswordSettings();"/>
|
||||
oninput="changePasswordSettings(false);"/>
|
||||
<label value="&managepassword.timeout.unit;" style="margin: 4px;"/>
|
||||
</hbox>
|
||||
</radiogroup>
|
||||
|
||||
Reference in New Issue
Block a user