aboutsummaryrefslogtreecommitdiffstats
path: root/ui/jquery.effects.core.js
diff options
context:
space:
mode:
authortomykaira <tomykaira@gmail.com>2011-06-09 20:36:48 -0500
committergnarf <gnarf@gnarf.net>2011-06-09 20:38:09 -0500
commit2c8151848d191ad9ba53c0ee86b14aefe4288f67 (patch)
tree43e306d0a16a06772f9b6616e18b539a09de13e3 /ui/jquery.effects.core.js
parent19dcac2129a2b39a24989835c1c732fa630bdefd (diff)
downloadjquery-ui-2c8151848d191ad9ba53c0ee86b14aefe4288f67.tar.gz
jquery-ui-2c8151848d191ad9ba53c0ee86b14aefe4288f67.zip
effects.core: Convert elements height/width to px and restore after animation in all effects. Fixed #5245 - Relative width elements break when wrapped for effects
Diffstat (limited to 'ui/jquery.effects.core.js')
-rw-r--r--ui/jquery.effects.core.js8
1 files changed, 7 insertions, 1 deletions
diff --git a/ui/jquery.effects.core.js b/ui/jquery.effects.core.js
index 7650aa8f4..00a803360 100644
--- a/ui/jquery.effects.core.js
+++ b/ui/jquery.effects.core.js
@@ -410,7 +410,12 @@ $.extend( $.effects, {
border: "none",
margin: 0,
padding: 0
- });
+ }),
+ // Store the size in case width/height are defined in % - Fixes #5245
+ size = {
+ width: element.width(),
+ height: element.height()
+ };
element.wrap( wrapper );
wrapper = element.parent(); //Hotfix for jQuery 1.4 since some change in wrap() seems to actually loose the reference to the wrapped element
@@ -438,6 +443,7 @@ $.extend( $.effects, {
bottom: "auto"
});
}
+ element.css(size);
return wrapper.css( props ).show();
},