mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Re-land pref fix for Clear Recent History. b=453440 r=gavin a=blocking-firefox3.1
This commit is contained in:
parent
4cb728c278
commit
4a12c6d2be
@ -102,10 +102,17 @@
|
||||
|
||||
sanitize: function ()
|
||||
{
|
||||
// Update pref values before handing off to the sanitizer (bug 453440)
|
||||
this.updatePrefs();
|
||||
var s = new Sanitizer();
|
||||
s.ignoreTimespan = false;
|
||||
s.prefDomain = "privacy.cpd.";
|
||||
s.sanitize();
|
||||
try {
|
||||
s.sanitize();
|
||||
} catch (er) {
|
||||
Components.utils.reportError("Exception during sanitize: " + er);
|
||||
}
|
||||
return true;
|
||||
},
|
||||
|
||||
onReadGeneric: function ()
|
||||
@ -155,6 +162,18 @@
|
||||
if (history.checked)
|
||||
downloads.checked = true;
|
||||
},
|
||||
|
||||
updatePrefs : function ()
|
||||
{
|
||||
var tsPref = document.getElementById("privacy.sanitize.timeSpan");
|
||||
Sanitizer.prefs.setIntPref("timeSpan", tsPref.value);
|
||||
var sanitizePreferences = document.getElementById("sanitizePreferences");
|
||||
var prefs = sanitizePreferences.rootBranch;
|
||||
for (var i = 0; i < sanitizePreferences.childNodes.length; ++i) {
|
||||
var p = sanitizePreferences.childNodes[i];
|
||||
prefs.setBoolPref(p.name, p.value);
|
||||
}
|
||||
}
|
||||
};
|
||||
]]>
|
||||
</script>
|
||||
|
Loading…
Reference in New Issue
Block a user