1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2026-01-07 22:44:12 +01:00

Add abbreviation hives and fix some apparently long standing abbreviation bugs in the process. :(

This commit is contained in:
Kris Maglione
2011-02-11 11:34:55 -05:00
parent 0899c52448
commit 0d4fe708a1
5 changed files with 172 additions and 124 deletions

View File

@@ -151,7 +151,7 @@ var Contexts = Module("contexts", {
memoize(contexts.Group.prototype, name, function () {
let group = constructor(this);
this.hives.push(group);
delete contexts.groups;
contexts.flush();
return group;
});
@@ -270,6 +270,11 @@ var Contexts = Module("contexts", {
activeGroups: function (hive) this.initializedGroups().filter(function (g) g.filter(this), this.modules.buffer.uri),
flush: function flush() {
delete this.groups;
delete this.allGroups;
},
initializedGroups: function (hive)
let (need = hive ? [hive] : Object.keys(this.hives))
this.groupList.filter(function (group) need.some(function (name) set.has(group, name))),
@@ -295,7 +300,7 @@ var Contexts = Module("contexts", {
group.persist = persist;
}
delete this.groups;
this.flush();
return group;
},
@@ -321,7 +326,7 @@ var Contexts = Module("contexts", {
delete this.groupMap[name];
delete this.hiveProto[name];
delete this.groups;
this.flush();
return group;
},