jQuery finish()Methods

jQuery 效果方法jQuery Effects Methods

Examples

Finish the currently running animation:

$("#complete").click(function(){ $("div").finish(); });

Try it Yourself »

Definition and Usage

The finish() method stops the currently running animation, removes all queued animations, and completes all animations for the selected elements.

This method is similar to the .stop(true,true) method, except that finish() also causes the CSS properties of all queued animations to stop.


Syntax

$(selector).finish(queueName)

Parameters Description
queueName Optional. Specifies the name of the queue to stop the animation.


jQuery 效果方法jQuery Effects Methods

Other Extensions