Thursday 15 March 2012

jquery - Is there a way to have .stop execute the last two queued animations -



jquery - Is there a way to have .stop execute the last two queued animations -

i'm using .stop() .animate , works except looks little glitchy when go on divs fast. think because jumping end of animation in doing lastly queued animation. wondering if there way have execute lastly 2 queued animations or create 1 executing end smoothly before origin lastly queued animation?

here's code have 4 of code segment in row 4 different images

$("#shakibimg").mouseenter(function(){ $(this).stop(true,true).animate({ width: '+=150px', marginleft: 0 }); $('#rona2img, #ronaimg, #ashurimg').stop(true,true).animate({ left: '+=150px', }); }); $('#shakibimg').mouseleave(function() { $(this).stop(true,true).animate({ width: '-=150px', marginleft: 0, }); $('#rona2img, #ronaimg, #ashurimg').stop(true,true).animate({ left: '-=150px', }); });

jquery css animation

No comments:

Post a Comment