From 48659c643f68b5fc070f122255b7c73b913f0281 Mon Sep 17 00:00:00 2001 From: rozwell Date: Thu, 5 Jan 2012 11:43:51 -0600 Subject: [PATCH] Effects: Blind effect bugfix - Pull Request #563 - No Ticket --- ui/jquery.effects.blind.js | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/ui/jquery.effects.blind.js b/ui/jquery.effects.blind.js index 5f86bed7b..abcc9eed8 100644 --- a/ui/jquery.effects.blind.js +++ b/ui/jquery.effects.blind.js @@ -27,7 +27,7 @@ $.effects.effect.blind = function( o, done ) { motion = rpositivemotion.test( direction ), animation = {}, show = mode === "show", - wrapper, distance; + wrapper, distance, margin; // if already wrapped, the wrapper's properties are my property. #6245 if ( el.parent().is( ".ui-effects-wrapper" ) ) { @@ -41,21 +41,23 @@ $.effects.effect.blind = function( o, done ) { }); distance = wrapper[ ref ](); + margin = parseInt(wrapper.css(ref2)); animation[ ref ] = show ? distance : 0; if ( !motion ) { el .css( vertical ? "bottom" : "right", 0 ) - .css( vertical ? "top" : "left", "" ) + .css( vertical ? "top" : "left", "auto" ) .css({ position: "absolute" }); - animation[ ref2 ] = show ? 0 : distance; + + animation[ ref2 ] = show ? margin : distance + margin; } // start at 0 if we are showing if ( show ) { wrapper.css( ref, 0 ); if ( ! motion ) { - wrapper.css( ref2, distance ); + wrapper.css( ref2, margin + distance ); } } -- 2.39.5