Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

creating an animation queue in jQuery that contains several DOM elements and animations and firing them sequentially? [duplicate]

Possible Duplicate:
A non-nested animation sequence in jQuery?

I have an html/css/js iOS app that currently has several animations that all trigger simultaneously. Not only is this not the desired affect, it's too much for some iOS devices to handle all at once and results in choppy animations.

What I'm looking to do is instead .animate() everything, I'd like to add the animations to a queue and then fire them off sequentially. The challenge here is that the animations are spread throughout the application.

I'm having trouble tracking down how to do this with .queue() — or anything else for that matter...

like image 571
S16 Avatar asked Nov 13 '22 21:11

S16


1 Answers

This example on the jQuery site may help some on this issue - where several animations are made on the same element. The example shows the use of queue to order animations all at once or sequentially:

http://api.jquery.com/animate/#example-2

also note MLMs comment above for queueing animations on several elements:

A non-nested animation sequence in jQuery?

like image 192
Jonathan Tonge Avatar answered Nov 15 '22 10:11

Jonathan Tonge