mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2026-02-10 08:55:47 +01:00
Dequote preference names in :set!
This commit is contained in:
@@ -1101,6 +1101,7 @@ var Options = Module("options", {
|
||||
invertBoolean = (postfix == "!");
|
||||
}
|
||||
|
||||
name = Option.dequote(name);
|
||||
if (name == "all" && reset)
|
||||
modules.commandline.input(_("pref.prompt.resetAll", config.host) + " ",
|
||||
function (resp) {
|
||||
|
||||
@@ -48,6 +48,7 @@ var Services = Module("Services", {
|
||||
this.add("json", "@mozilla.org/dom/json;1", "nsIJSON", "createInstance");
|
||||
this.add("listeners", "@mozilla.org/eventlistenerservice;1", "nsIEventListenerService");
|
||||
this.add("livemark", "@mozilla.org/browser/livemark-service;2", "nsILivemarkService");
|
||||
this.add("messages", "@mozilla.org/globalmessagemanager;1", "nsIChromeFrameMessageManager");
|
||||
this.add("mime", "@mozilla.org/mime;1", "nsIMIMEService");
|
||||
this.add("observer", "@mozilla.org/observer-service;1", "nsIObserverService");
|
||||
this.add("pref", "@mozilla.org/preferences-service;1", ["nsIPrefBranch2", "nsIPrefService"]);
|
||||
|
||||
@@ -422,7 +422,7 @@ var Util = Module("Util", XPCOM([Ci.nsIObserver, Ci.nsISupportsWeakReference]),
|
||||
* @returns [string] The resulting strings.
|
||||
*/
|
||||
debrace: function debrace(pattern) {
|
||||
let res = [];
|
||||
var res = [];
|
||||
|
||||
if (isArray(pattern)) {
|
||||
let rec = function rec(acc) {
|
||||
@@ -1117,10 +1117,13 @@ var Util = Module("Util", XPCOM([Ci.nsIObserver, Ci.nsISupportsWeakReference]),
|
||||
}),
|
||||
|
||||
/**
|
||||
* Flushes the startup cache.
|
||||
* Flushes the startup or jar cache.
|
||||
*/
|
||||
flushCache: function flushCache() {
|
||||
services.observer.notifyObservers(null, "startupcache-invalidate", "");
|
||||
flushCache: function flushCache(file) {
|
||||
if (file)
|
||||
services.observer.notifyObservers(file, "flush-cache-entry", "");
|
||||
else
|
||||
services.observer.notifyObservers(null, "startupcache-invalidate", "");
|
||||
},
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user