mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2026-02-26 23:25:47 +01:00
Don't duplicate group properties in subgroups.
--HG-- branch : groups
This commit is contained in:
@@ -37,9 +37,7 @@ var Group = Class("Group", {
|
|||||||
|
|
||||||
this.Group = constructor;
|
this.Group = constructor;
|
||||||
this.name = name;
|
this.name = name;
|
||||||
memoize(Group.prototype, name,
|
memoize(Group.prototype, name, function () constructor(this));
|
||||||
function () constructor(this.name, this.description,
|
|
||||||
this.filter, this.persist));
|
|
||||||
|
|
||||||
memoize(Group.subGroupMap, name,
|
memoize(Group.subGroupMap, name,
|
||||||
function () Object.create(Object.create(contexts.subGroupProto,
|
function () Object.create(Object.create(contexts.subGroupProto,
|
||||||
|
|||||||
@@ -138,16 +138,14 @@ var Map = Class("Map", {
|
|||||||
});
|
});
|
||||||
|
|
||||||
var MapHive = Class("MapHive", {
|
var MapHive = Class("MapHive", {
|
||||||
init: function init(name, description, filter) {
|
init: function init(group) {
|
||||||
this.name = name;
|
this.group = group;
|
||||||
this.stacks = {};
|
this.stacks = {};
|
||||||
this.description = description;
|
|
||||||
this.filter = filter || function (uri) true;
|
|
||||||
},
|
},
|
||||||
|
|
||||||
get toStringParams() [this.name],
|
get toStringParams() [this.group.name],
|
||||||
|
|
||||||
get builtin() mappings.builtinHives.indexOf(this) >= 0,
|
get builtin() this.group.builtin,
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Iterates over all mappings present in all of the given *modes*.
|
* Iterates over all mappings present in all of the given *modes*.
|
||||||
|
|||||||
Reference in New Issue
Block a user