aboutsummaryrefslogtreecommitdiffstats
path: root/ui/jquery.effects.fade.js
diff options
context:
space:
mode:
authorScott González <scott.gonzalez@gmail.com>2012-06-14 21:01:14 -0400
committerScott González <scott.gonzalez@gmail.com>2012-06-15 07:35:08 -0400
commitd569b52838594c3e7e732d31dbf07dc2072edfdb (patch)
treea511afe8b3a843bd17db93149f762e1477a470eb /ui/jquery.effects.fade.js
parente2bbe04bc71aabdd93b49b960dd866a9681d4d4d (diff)
downloadjquery-ui-d569b52838594c3e7e732d31dbf07dc2072edfdb.tar.gz
jquery-ui-d569b52838594c3e7e732d31dbf07dc2072edfdb.zip
Effects (fade): Delegate hiding and showing to core. Fixes #8267 - dialog fadein broken since 1.9m4.
Diffstat (limited to 'ui/jquery.effects.fade.js')
-rw-r--r--ui/jquery.effects.fade.js15
1 files changed, 4 insertions, 11 deletions
diff --git a/ui/jquery.effects.fade.js b/ui/jquery.effects.fade.js
index 66029b51c..3989ee908 100644
--- a/ui/jquery.effects.fade.js
+++ b/ui/jquery.effects.fade.js
@@ -14,23 +14,16 @@
$.effects.effect.fade = function( o, done ) {
var el = $( this ),
- mode = $.effects.setMode( el, o.mode || "toggle" ),
- hide = mode === "hide";
+ mode = $.effects.setMode( el, o.mode || "toggle" );
- el.show();
el.animate({
- opacity: hide ? 0 : 1
+ opacity: mode
}, {
queue: false,
duration: o.duration,
easing: o.easing,
- complete: function() {
- if ( hide ) {
- el.hide();
- }
- done();
- }
+ complete: done
});
};
-})(jQuery);
+})( jQuery );