Re: beforescroll and using DOM events for extensibility

On Fri, Oct 3, 2014 at 11:38 AM, Olli Pettay <olli@pettay.fi> wrote:

> On 10/03/2014 06:26 PM, Rick Byers wrote:
>
>> On Fri, Oct 3, 2014 at 10:00 AM, Olli Pettay <olli@pettay.fi <mailto:
>> olli@pettay.fi>> wrote:
>>
>
>
>>     So something like element.requestScroll(x, y); could be exposed to
>> the web pages and it would behave as if user had initiated the scroll
>>     (at least in most cases. Maybe we'll need something like trusted
>> scroll which is coming from user).
>>
>>
>> We already have that - Element.scrollBy. What we don't have is a way to
>> customize how scroll inputs (deltas) are distributed to the outputs (which
>> element(s) will respond).
>>
>
>
> Which is why I think we should have another method which propagates
> scrolling request to the nearest scrollable element or so.


The challenge is that "nearest scrollable element" is exactly what needs to
be customizable.  Eg. imagine I'm implementing a 3d spinning carousel.
It's just a DIV, not scrollable by any native browser scroll logic.  How
should this DIV register itself as being a handler of scroll gestures?


>
> -Olli
>

Received on Friday, 3 October 2014 16:11:23 UTC