mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2026-02-19 11:25:46 +01:00
Get rid of horrible coalesced event handlers in commandline.js.
--HG-- branch : key-processing
This commit is contained in:
@@ -131,6 +131,16 @@ var Template = Module("Template", {
|
||||
update: function update() {
|
||||
this.collapsed = !this.commandAllowed;
|
||||
}
|
||||
}),
|
||||
|
||||
Events: Class("Events", Binding, {
|
||||
init: function init(node, params) {
|
||||
init.supercall(this, node);
|
||||
|
||||
let obj = params.eventTarget;
|
||||
for (let [event, handler] in Iterator(obj[this.getAttribute("events") || "events"]))
|
||||
node.addEventListener(event, obj.closure(handler), false);
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
|
||||
Reference in New Issue
Block a user