aboutsummaryrefslogtreecommitdiffstats
path: root/ui/jquery.effects.fade.js
diff options
context:
space:
mode:
authorgnarf <gnarf@gnarf.net>2011-06-21 01:11:46 -0500
committergnarf <gnarf@gnarf.net>2011-06-21 01:18:19 -0500
commitab627e03a6a37cbf3291e9600f5482bd50991360 (patch)
treecda0933741895ef198be19813cb45168889ea78f /ui/jquery.effects.fade.js
parent65a6c46e5568c43a9df9505e23da6a766814557e (diff)
downloadjquery-ui-ab627e03a6a37cbf3291e9600f5482bd50991360.tar.gz
jquery-ui-ab627e03a6a37cbf3291e9600f5482bd50991360.zip
Effects.*: DRY the complete callback execution into the 'done' callback passed into an effect
Diffstat (limited to 'ui/jquery.effects.fade.js')
-rw-r--r--ui/jquery.effects.fade.js7
1 files changed, 2 insertions, 5 deletions
diff --git a/ui/jquery.effects.fade.js b/ui/jquery.effects.fade.js
index 8f2d956dc..9b79ad3bc 100644
--- a/ui/jquery.effects.fade.js
+++ b/ui/jquery.effects.fade.js
@@ -12,7 +12,7 @@
*/
(function( $, undefined ) {
-$.effects.effect.fade = function( o, next ) {
+$.effects.effect.fade = function( o, done ) {
var el = $( this ),
mode = $.effects.setMode( el, o.mode || "toggle" ),
hide = mode === "hide";
@@ -28,10 +28,7 @@ $.effects.effect.fade = function( o, next ) {
if ( hide ) {
el.hide();
}
- if ( o.complete ) {
- o.complete.call( this );
- }
- next();
+ done();
}
});
};