]> source.dussan.org Git - jquery.git/commitdiff
jquery fx: closes #3496. $.fx.off = true; turns off animations.
authorAriel Flesler <aflesler@gmail.com>
Wed, 22 Oct 2008 15:23:37 +0000 (15:23 +0000)
committerAriel Flesler <aflesler@gmail.com>
Wed, 22 Oct 2008 15:23:37 +0000 (15:23 +0000)
src/fx.js

index 8cb7b99a9ce7d492f63b71cbc571da10e947ebda..3fe936909971d8676dc80e2090239f5df75e5e9f 100644 (file)
--- a/src/fx.js
+++ b/src/fx.js
@@ -208,7 +208,7 @@ jQuery.extend({
                        easing: fn && easing || easing && easing.constructor != Function && easing
                };
 
-               opt.duration = typeof opt.duration == 'number' ? opt.duration :
+               opt.duration = jQuery.fx.off ? 0 : typeof opt.duration == 'number' ? opt.duration :
                        jQuery.fx.speeds[opt.duration] || jQuery.fx.speeds._default;
 
                // Queueing