mirror of
https://github.com/classilla/tenfourfox.git
synced 2024-11-13 09:04:55 +00:00
18 lines
561 B
JavaScript
18 lines
561 B
JavaScript
var offlineByDefault = {
|
|
defaultValue: false,
|
|
prefBranch: SpecialPowers.Cc["@mozilla.org/preferences-service;1"].getService(SpecialPowers.Ci.nsIPrefBranch),
|
|
set: function(allow) {
|
|
try {
|
|
this.defaultValue = this.prefBranch.getBoolPref("offline-apps.allow_by_default");
|
|
} catch (e) {
|
|
this.defaultValue = false
|
|
}
|
|
this.prefBranch.setBoolPref("offline-apps.allow_by_default", allow);
|
|
},
|
|
reset: function() {
|
|
this.prefBranch.setBoolPref("offline-apps.allow_by_default", this.defaultValue);
|
|
}
|
|
}
|
|
|
|
offlineByDefault.set(false);
|