File tree Expand file tree Collapse file tree 1 file changed +3
-20
lines changed
Expand file tree Collapse file tree 1 file changed +3
-20
lines changed Original file line number Diff line number Diff line change @@ -13,10 +13,7 @@ var elemdisplay = {},
1313 // opacity animations
1414 [ "opacity" ]
1515 ] ,
16- fxNow ,
17- requestAnimationFrame = window . webkitRequestAnimationFrame ||
18- window . mozRequestAnimationFrame ||
19- window . oRequestAnimationFrame ;
16+ fxNow ;
2017
2118jQuery . fn . extend ( {
2219 show : function ( speed , easing , callback ) {
@@ -392,8 +389,7 @@ jQuery.fx.prototype = {
392389 // Start an animation from one number to another
393390 custom : function ( from , to , unit ) {
394391 var self = this ,
395- fx = jQuery . fx ,
396- raf ;
392+ fx = jQuery . fx ;
397393
398394 this . startTime = fxNow || createFxNow ( ) ;
399395 this . start = from ;
@@ -409,20 +405,7 @@ jQuery.fx.prototype = {
409405 t . elem = this . elem ;
410406
411407 if ( t ( ) && jQuery . timers . push ( t ) && ! timerId ) {
412- // Use requestAnimationFrame instead of setInterval if available
413- if ( requestAnimationFrame ) {
414- timerId = true ;
415- raf = function ( ) {
416- // When timerId gets set to null at any point, this stops
417- if ( timerId ) {
418- requestAnimationFrame ( raf ) ;
419- fx . tick ( ) ;
420- }
421- } ;
422- requestAnimationFrame ( raf ) ;
423- } else {
424- timerId = setInterval ( fx . tick , fx . interval ) ;
425- }
408+ timerId = setInterval ( fx . tick , fx . interval ) ;
426409 }
427410 } ,
428411
You can’t perform that action at this time.
0 commit comments