aboutsummaryrefslogtreecommitdiffstats
path: root/src/effects.js
diff options
context:
space:
mode:
authortimmywil <timmywillisn@gmail.com>2012-01-20 14:17:02 -0500
committertimmywil <timmywillisn@gmail.com>2012-01-20 14:17:19 -0500
commite8673ae1aafe16a8a7f855958f545c710bf8133e (patch)
tree0fa2cf3257804215f7d8966293bd9dce7d24178b /src/effects.js
parent135bb4ff812d9f97b961670ad9c4ed9d14f333bb (diff)
downloadjquery-e8673ae1aafe16a8a7f855958f545c710bf8133e.tar.gz
jquery-e8673ae1aafe16a8a7f855958f545c710bf8133e.zip
When stopping a show, save showing end state instead of start state to fix animation toggling issue. Fixes #10848.
Diffstat (limited to 'src/effects.js')
-rw-r--r--src/effects.js8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/effects.js b/src/effects.js
index 6716e616a..346438174 100644
--- a/src/effects.js
+++ b/src/effects.js
@@ -462,8 +462,12 @@ jQuery.fx.prototype = {
t.queue = this.options.queue;
t.elem = this.elem;
t.saveState = function() {
- if ( self.options.hide && jQuery._data( self.elem, "fxshow" + self.prop ) === undefined ) {
- jQuery._data( self.elem, "fxshow" + self.prop, self.start );
+ if ( jQuery._data( self.elem, "fxshow" + self.prop ) === undefined ) {
+ if ( self.options.hide ) {
+ jQuery._data( self.elem, "fxshow" + self.prop, self.start );
+ } else if ( self.options.show ) {
+ jQuery._data( self.elem, "fxshow" + self.prop, self.end );
+ }
}
};