In bug 246719, I'm trying to make middle-clicking on more elements work, using
oncommand="var url = ...; openUILink(url, event);"
If I middle-click an element with this before left-clicking it, I get
"this.oncommand is not a function" and openUILink is not called. If I
left-click first, it works fine when I middle-click.
Workaround: use eval. eval(this.getAttribute('oncommand'))
I don't like this workaround because using eval in chrome JS can be dangerous,
and because it's more code than this.oncommand(event).
email@example.com had the same problem in bug 230401. Once this is
fixed, the code from bug 230401 and bug 246719 should be changed to not use eval().
*** Bug 284250 has been marked as a duplicate of this bug. ***
Note that we do have a .doCommand but it doesn't take an existing event.