Metoda jQuery finish() .

❮ Metody efektů jQuery

Příklad

Dokončete aktuálně běžící animaci:

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

Definice a použití

Metoda finish() zastaví aktuálně spuštěné animace, odstraní všechny animace ve frontě a dokončí všechny animace pro vybrané prvky.

Tato metoda je podobná metodě .stop(true,true), kromě toho, že finish() také způsobí zastavení vlastnosti CSS všech animací zařazených do fronty.


Syntax

$(selector).finish(queueName)

Parameter Description
queueName Optional. Specifies the name of the queue to stop animations

❮ Metody efektů jQuery