Klaus Hartl schrieb:
> Brice Burgess schrieb:
>
>> Karl Rudd wrote:
>>
>>> The $() you have at the moment just binds to the document. You
>>> probably want $('*'), which selects all elements on the page.
>>>
>>> Karl Rudd
>>>
>> That makes more sense... although would it be wise to do (efficient-wise
>> that is?). It seems that on a large page, that would assign *many*,
>> *many*, maybe too many events? I took the code direct from blockUI. What
>> blockUI may be doing is intercepting the events via a masking overlay?
>>
>> Perhaps it would be better to add a transparent covering element
>> (overlay) to intercept clicks?
>>
>> ~ Brice
>>
>
> You won't need that and it would be very (very, very) inefficient,
> because every event passes the document (in capture phase for the W3C
> event model) and bubbles again along in bubbling phase (IE and W3C event
> model).
>
> That said, I don't know why it fails. Have you tried to put the document
> element explicitly into the query?
>
Considering this article http://www.quirksmode.org/js/events_order.html
and jQuery's event handling, it must fail, because all events use
bubbling instead of capturing, in other words, the event handlers on the
document are called last, after every other event handler executed.
--
Jörn Zaefferer
http://bassistance.de
_______________________________________________
jQuery mailing list
[email protected]
http://jquery.com/discuss/