1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2026-01-08 17:14:12 +01:00

Replace expression closures (getters).

Expression closures are to be axed. See https://bugzil.la/1083458.
This commit is contained in:
Doug Kearns
2015-05-27 04:42:30 +10:00
parent ce82387cdd
commit 6e8040286a
48 changed files with 808 additions and 532 deletions

View File

@@ -30,9 +30,9 @@ var Overlay = Class("Overlay", {
cleanups: Class.Memoize(() => []),
objects: Class.Memoize(() => ({})),
get doc() this.window.document,
get doc() { return this.window.document; },
get win() this.window,
get win() { return this.window; },
$: function $(sel, node) DOM(sel, node || this.doc),
@@ -463,9 +463,11 @@ var Overlay = Module("Overlay", XPCOM([Ci.nsIObserver, Ci.nsISupportsWeakReferen
};
},
get activeModules() this.activeWindow && this.activeWindow.dactyl.modules,
get activeModules() {
return this.activeWindow && this.activeWindow.dactyl.modules;
},
get modules() [w.dactyl.modules for (w of this.windows)],
get modules() { return [w.dactyl.modules for (w of this.windows)]; },
/**
* The most recently active dactyl window.
@@ -475,7 +477,7 @@ var Overlay = Module("Overlay", XPCOM([Ci.nsIObserver, Ci.nsISupportsWeakReferen
return this.windows.has(win) && win;
},
set activeWindow(win) this._activeWindow = util.weakReference(win),
set activeWindow(win) { this._activeWindow = util.weakReference(win); },
/**
* A list of extant dactyl windows.