]> source.dussan.org Git - jquery-ui.git/commitdiff
Fixed #3058
authorEduardo Lundgren <eduardolundgren@gmail.com>
Fri, 16 Jan 2009 05:57:34 +0000 (05:57 +0000)
committerEduardo Lundgren <eduardolundgren@gmail.com>
Fri, 16 Jan 2009 05:57:34 +0000 (05:57 +0000)
ui/ui.resizable.js

index 709468ce9fcc3c5ea23f9a9c6667d3c60f8386f8..2c7d30fb1fd45adc3dae9a48aa7f3224019cf2f7 100644 (file)
@@ -449,9 +449,13 @@ $.widget("ui.resizable", $.extend({}, $.ui.mouse, {
                                return border + padding;
                        });
                }
+
+               if ($.browser.msie && !isVisible(el))
+                       return;
+
                prel.css({
-                       height: (el.height() - o.borderDif[0] - o.borderDif[2]) + "px",
-                       width: (el.width() - o.borderDif[1] - o.borderDif[3]) + "px"
+                       height: (el.height() - o.borderDif[0] - o.borderDif[2]) || 0,
+                       width: (el.width() - o.borderDif[1] - o.borderDif[3]) || 0
                });
        },
 
@@ -824,4 +828,8 @@ $.ui.plugin.add("resizable", "grid", {
 
 });
 
+function isVisible(element) {
+       return !($(element).is(':hidden') || $(element).parents(':hidden').length);
+}
+
 })(jQuery);