1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2025-12-20 15:07:57 +01:00

Move some more strings to messages.properties and report (but don't throw) an error for unknown strings.

This commit is contained in:
Kris Maglione
2011-03-02 02:59:04 -05:00
parent 28d1c1bcad
commit e032a82d62
9 changed files with 147 additions and 103 deletions

View File

@@ -302,10 +302,12 @@ var EventHive = Class("EventHive", Contexts.Hive, {
* phase, otherwise during the bubbling phase.
*/
listen: function (target, event, callback, capture, allowUntrusted) {
if (isObject(event))
var [self, events] = [event, event[callback || "events"]];
else
[self, events] = [null, array.toObject([[event, callback]])];
if (!isObject(event))
var [self, events] = [null, array.toObject([[event, callback]])];
else {
[self, events] = [event, event[callback || "events"]];
[,, capture, allowUntrusted] = arguments;
}
for (let [event, callback] in Iterator(events)) {
let args = [Cu.getWeakReference(target),