Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Javascript > Passing arguments to callback function in addEventListener

Reply
Thread Tools

Passing arguments to callback function in addEventListener

 
 
Richard Cornford
Guest
Posts: n/a
 
      01-11-2007
Paul wrote:
> Richard Cornford wrote:
>> Elegie wrote:
>> <snip>
>>> [4] Instead of passing the handler directly, pass some object
>>> implementing the EventListener interface.

>>
>> That is very risky in javascript. The W3C ECMAScript bindings for the
>> EventListener interface effectively say that any _function_ is an
>> EventListener. ...

<snip>

> The OP mentioned he was developing a greasemonkey script for firefox.


Being able to disregard the applicable standard because the context of
application allows more is not reason for doing so in itself.

Richard.

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
document.addEventListener over window.addEventListener William Wallace Javascript 25 08-14-2010 01:10 AM
addEventListener / attachEvent and passing 'this' to handler Erwin Moller Javascript 13 07-26-2009 11:51 AM
How do I create a function in my library for passing user callback function Angus C Programming 32 04-15-2008 02:28 PM
how to pass a function name and its arguments inside the arguments of other function? jmborr Python 1 11-03-2007 08:20 AM
addEventListener function in IE Michael Hill Javascript 3 07-21-2004 09:25 AM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57