Hi,
i once did such stuff using morph(), maybe it is portable to your
needs with scroll():
var offsets = {
'left' : '9px',
'right' : '240px',
'direction' : 'right'
};
var posLEFT, posRIGHT;
var Mover = new Fx.Morph($('myLovelyDIV'),{
'duration' : 3000,
'unit' : 'px',
'onComplete' : function(){
offsets.direction = offsets.direction == 'left' ?
'right' : 'left';
if( offsets.direction == 'left' )
Mover.start({ left : offsets.left});
else
Mover.start({ left : offsets.right});
}
}).start({
left : [offsets.left,offsets.right]
});
There might be a more optimized way but this works - see my "MooTools
Loading Box 1.0" over at:
http://dev.artness.de/
Hope this may help
On 16 Okt., 04:58, mmjaeger <[email protected]> wrote:
> Hello
> Please allow me a quick question - I got the following code:
>
> <code>
> var fxScroll = new Fx.Scroll($('randomImageContainer'), {
> duration: 10000,
> wait: false
> }).toRight().chain(function(){
> this.toLeft.delay(2500, this);
> });
> </code>
>
> this scrolls to the right and then back to the left - what I don't see
> is how I could basically use it to run endless (in a loop)
>
> thank you in advance for your help.