]> source.dussan.org Git - jquery-ui.git/commitdiff
effects.core: fixed parsing of IE left/top values in createWrapper (closes #2915)
authorPaul Bakaus <paul.bakaus@googlemail.com>
Sun, 25 May 2008 15:50:29 +0000 (15:50 +0000)
committerPaul Bakaus <paul.bakaus@googlemail.com>
Sun, 25 May 2008 15:50:29 +0000 (15:50 +0000)
ui/source/effects.core.js

index 8841cf59b618d1e3cbb31f2dc58d4ef4e68375bf..b44a7227492f48a315e8692adf8d6ae1d5169ea8 100644 (file)
@@ -44,8 +44,8 @@
         wrapper.css({position: 'relative'});
         el.css({position: 'relative'});
       } else {
-        var top = parseInt(el.css('top'), 10); if (top.constructor != Number) top = 'auto';
-        var left = parseInt(el.css('left'), 10); if (left.constructor != Number) left = 'auto';
+        var top = parseInt(el.css('top'), 10); if(isNaN(top)) top = 'auto';
+        var left = parseInt(el.css('left'), 10); if(isNaN(top)) left = 'auto';
         wrapper.css({ position: el.css('position'), top: top, left: left, zIndex: el.css('z-index') }).show();
         el.css({position: 'relative', top:0, left:0});
       }