diff options
author | gnarf <gnarf@gnarf.net> | 2011-06-21 01:11:46 -0500 |
---|---|---|
committer | gnarf <gnarf@gnarf.net> | 2011-06-21 01:18:19 -0500 |
commit | ab627e03a6a37cbf3291e9600f5482bd50991360 (patch) | |
tree | cda0933741895ef198be19813cb45168889ea78f /ui/jquery.effects.highlight.js | |
parent | 65a6c46e5568c43a9df9505e23da6a766814557e (diff) | |
download | jquery-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.highlight.js')
-rw-r--r-- | ui/jquery.effects.highlight.js | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/ui/jquery.effects.highlight.js b/ui/jquery.effects.highlight.js index 709e93a3c..edde845a3 100644 --- a/ui/jquery.effects.highlight.js +++ b/ui/jquery.effects.highlight.js @@ -12,7 +12,7 @@ */ (function( $, undefined ) { -$.effects.effect.highlight = function( o, next ) { +$.effects.effect.highlight = function( o, done ) { var elem = $( this ), props = [ "backgroundImage", "backgroundColor", "opacity" ], mode = $.effects.setMode( elem, o.mode || "show" ), @@ -41,10 +41,7 @@ $.effects.effect.highlight = function( o, next ) { elem.hide(); } $.effects.restore( elem, props ); - if ( $.isFunction( o.complete) ) { - o.complete.apply( this, arguments ); - } - next(); + done(); } }); }; |