[whatwg] Scroll events + bubbling?

Anne van Kesteren annevk at opera.com
Mon Jul 14 11:42:50 PDT 2008


On Mon, 14 Jul 2008 20:36:12 +0200, Brady Eidson <beidson at apple.com> wrote:
>  From the current spec:
> "onscroll - Must be invoked whenever a scroll event is targeted at or  
> bubbles through the element."
>
> Yet IE and Firefox don't, and WebKit is currently considering matching  
> them for compatibility...  it seems that folks agree scroll events  
> shouldn't bubble.
>
> Can we update the spec to match this?

onscroll is just an event listener just like the other on* attributes are.  
They do not define how events are dispatched and whether these are  
bubbling, cancable, et cetera.

(I haven't tested this but it might very well be that if you dispatch a  
custom bubbling event named scroll the onscroll attribute of an ancestor  
element, of the element on which you dispatch it, might very well trigger.)


-- 
Anne van Kesteren
<http://annevankesteren.nl/>
<http://www.opera.com/>



More information about the whatwg mailing list