X-Git-Url: https://git.donarmstrong.com/?p=dactyl.git;a=blobdiff_plain;f=common%2Fmodules%2Fprefs.jsm;fp=common%2Fmodules%2Fprefs.jsm;h=47fec508aafeb08c2fb4d63c998e8bf9ffa4d46b;hp=d01d1c26041237d746f7a70f815bea9b902dc021;hb=354a049cce8415487552ce405cce167b7071fe1f;hpb=3d837eb266a3a01d424192aa4ec1a167366178c5 diff --git a/common/modules/prefs.jsm b/common/modules/prefs.jsm index d01d1c2..47fec50 100644 --- a/common/modules/prefs.jsm +++ b/common/modules/prefs.jsm @@ -1,6 +1,6 @@ // Copyright (c) 2006-2008 by Martin Stubenschrott // Copyright (c) 2007-2011 by Doug Kearns -// Copyright (c) 2008-2012 Kris Maglione +// Copyright (c) 2008-2013 Kris Maglione // // This work is licensed for reuse under an MIT license. Details are // given in the LICENSE.txt file included with this file. @@ -375,7 +375,8 @@ var Prefs = Module("prefs", XPCOM([Ci.nsIObserver, Ci.nsISupportsWeakReference]) if (!this._observers[pref]) this._observers[pref] = []; - this._observers[pref].push(!strong ? util.weakReference(callback) : { get: function () callback }); + this._observers[pref].push(!strong ? util.weakReference(callback) + : { get: function () callback }); }, /** @@ -422,13 +423,14 @@ var Prefs = Module("prefs", XPCOM([Ci.nsIObserver, Ci.nsISupportsWeakReference]) modules.completion.preference = function preference(context) { context.anchored = false; context.title = [config.host + " Preference", "Value"]; - context.keys = { text: function (item) item, description: function (item) prefs.get(item) }; + context.keys = { text: function (item) item, + description: function (item) prefs.get(item) }; context.completions = prefs.getNames(); }; }, javascript: function init_javascript(dactyl, modules) { modules.JavaScript.setCompleter([this.get, this.safeSet, this.set, this.reset, this.toggle], - [function (context) (context.anchored=false, this.getNames().map(function (pref) [pref, ""]))]); + [function (context) (context.anchored=false, this.getNames().map(pref => [pref, ""]))]); } });