mirror of
https://github.com/jquery/jquery.git
synced 2026-04-20 03:01:22 -04:00
Fix #12803. Add jQuery.fx.start as a hook point. Close gh-1024.
This commit is contained in:
committed by
Dave Methvin
parent
84629a9b87
commit
516a7a8792
10
src/effects.js
vendored
10
src/effects.js
vendored
@@ -640,13 +640,19 @@ jQuery.fx.tick = function() {
|
||||
};
|
||||
|
||||
jQuery.fx.timer = function( timer ) {
|
||||
if ( timer() && jQuery.timers.push( timer ) && !timerId ) {
|
||||
timerId = setInterval( jQuery.fx.tick, jQuery.fx.interval );
|
||||
if ( timer() && jQuery.timers.push( timer ) ) {
|
||||
jQuery.fx.start();
|
||||
}
|
||||
};
|
||||
|
||||
jQuery.fx.interval = 13;
|
||||
|
||||
jQuery.fx.start = function() {
|
||||
if ( !timerId ) {
|
||||
timerId = setInterval( jQuery.fx.tick, jQuery.fx.interval );
|
||||
}
|
||||
};
|
||||
|
||||
jQuery.fx.stop = function() {
|
||||
clearInterval( timerId );
|
||||
timerId = null;
|
||||
|
||||
Reference in New Issue
Block a user