Bug 973658 - Actually revert the value of the Permanent Private Browsing pref when the user presses Cancel in response to the restart dialog; r=jdm

Before we were implicitly relying on the pref being reverted through
the checkbox, but that won't happen if the checkbox was never clicked
by the user.
This commit is contained in:
Ehsan Akhgari 2014-02-18 08:49:39 -05:00
parent 9df66916f4
commit 8e4c83b3d6
2 changed files with 4 additions and 2 deletions

View File

@ -247,7 +247,7 @@ var gPrivacyPane = {
},
_lastMode: null,
_lasCheckState: null,
_lastCheckState: null,
updateAutostart: function PPP_updateAutostart() {
let mode = document.getElementById("historyMode");
let autoStart = document.getElementById("privateBrowsingAutoStart");
@ -299,6 +299,7 @@ var gPrivacyPane = {
} else {
autoStart.removeAttribute('checked');
}
pref.value = autoStart.hasAttribute('checked');
mode.selectedIndex = this._lastMode;
mode.doCommand();

View File

@ -249,7 +249,7 @@ var gPrivacyPane = {
},
_lastMode: null,
_lasCheckState: null,
_lastCheckState: null,
updateAutostart: function PPP_updateAutostart() {
let mode = document.getElementById("historyMode");
let autoStart = document.getElementById("privateBrowsingAutoStart");
@ -301,6 +301,7 @@ var gPrivacyPane = {
} else {
autoStart.removeAttribute('checked');
}
pref.value = autoStart.hasAttribute('checked');
mode.selectedIndex = this._lastMode;
mode.doCommand();