"Auto targets all the anchors in a page and display a smooth scrolling effect 
upon clicking them." -http://mootools.net/docs/more/Fx/Fx.SmoothScroll

"Scrolls any element with an overflow, including the window element." 
-http://mootools.net/docs/more/Fx/Fx.Scroll

You don't need toElement on SmoothScroll, it's a sub class of Fx.Scroll that 
you simply instantiate, it adds all the events to all the anchors tags that 
reference an element on the page.

Fx.Scroll is simply the effect w/ no events added to anything, you have to 
control it.

On Mar 12, 2010, at 2:36 AM, hamburger wrote:

> Thx Ryan,
> i defined an FX.Scroll and it works how i want it.
> I really don't understand the different between SmoothScroll an
> FX.Scroll.
> for me both do the same thing:
>                                 new SmoothScroll({ duration:
> 1000,offset: {'x': 0,'y': -40}}, window).toElement(this.list[0]);
>                                 new Fx.Scroll(window, {duration:
> 1000,offset: {'x': 0,'y': -40}}).toElement(this.list[0]);
> 
> 
> On 11 Mrz., 17:25, Ryan Florence <[email protected]> wrote:
>> SmoothScroll is designed to be an all encompassing script for the whole 
>> page, so they are adding events to the same elements.
>> 
>> You need to set up two different Fx.Scroll instances on the body, you'll 
>> have complete control.  Check the docs for more help.
>> 
>> On Mar 11, 2010, at 6:58 AM, hamburger wrote:
>> 
>> 
>> 
>>> Hello I'am using on one page two SmoothScrolls.
>>> the first i define with:
>>> var tatta = new SmoothScroll({duration:500});
>> 
>>> the second with:
>>> var mySmmotth = new SmoothScroll({ duration:1000,offset: {'x': 0,'y':
>>> -40}}, window).toElement(this.list[0]);
>> 
>>> if i execute the second the first one will not run in the way before.
>> 
>>> how to define two Smoothies??- Zitierten Text ausblenden -
>> 
>> - Zitierten Text anzeigen -

Reply via email to