1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2026-01-27 14:55:48 +01:00

Deal with some duplicated code, plus some collateral optimization.

This commit is contained in:
Kris Maglione
2010-10-17 22:43:30 -04:00
parent f2242c3567
commit 1e3ce10290
2 changed files with 244 additions and 234 deletions

View File

@@ -528,6 +528,8 @@ function memoize(obj, key, getter) {
obj.__defineGetter__(key, function replace() (
Class.replaceProperty(this.instance || this, key, null),
Class.replaceProperty(this.instance || this, key, getter.call(this, key))));
obj.__defineSetter__(key, function replace(val)
Class.replaceProperty(this.instance || this, key, val));
}
/**