dojo:how to know whether a event handler is bound to a particular dom element
Say for example i have clickHandler a function, then i do
dojo.connect(开发者_如何学JAVAdomEl,'click',clickHandler).
Is there any wayto check whether clickHandler is used as a click event handler for domEl using dojo?
Yes. For example:
var clickHandler = function(evt) {
var domEl = evt.target;
// Now domEl is dom node where the click ocurred
...
}
精彩评论