diff options
author | Eduardo Lundgren <eduardolundgren@gmail.com> | 2008-06-01 20:06:21 +0000 |
---|---|---|
committer | Eduardo Lundgren <eduardolundgren@gmail.com> | 2008-06-01 20:06:21 +0000 |
commit | 6f2849fd382868d1c29bca9d4624d76756049916 (patch) | |
tree | 2a69ae1e456ca8670ffbfeeb5866aed17c1d68ab | |
parent | dce035cc658a5bcbbeb7e27c6d635882e0617b93 (diff) | |
download | jquery-ui-6f2849fd382868d1c29bca9d4624d76756049916.tar.gz jquery-ui-6f2849fd382868d1c29bca9d4624d76756049916.zip |
alsoResize IE bug fixes
-rw-r--r-- | ui/source/ui.resizable.js | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/ui/source/ui.resizable.js b/ui/source/ui.resizable.js index e94cfee58..10a2ce2f5 100644 --- a/ui/source/ui.resizable.js +++ b/ui/source/ui.resizable.js @@ -684,8 +684,8 @@ _store = function(exp) {
$(exp).each(function() {
- $(this).data("resizable-alsoresize-start", {
- width: parseInt($(this).css('width'), 10), height: parseInt($(this).css('height'), 10),
+ $(this).data("resizable-alsoresize", {
+ width: parseInt($(this).width(), 10), height: parseInt($(this).height(), 10),
left: parseInt($(this).css('left'), 10), top: parseInt($(this).css('top'), 10)
});
});
@@ -708,12 +708,13 @@ _alsoResize = function(exp, c) {
$(exp).each(function() {
- var start = $(this).data("resizable-alsoresize-start"), style = {}, css = c && c.length ? c : ['width', 'height', 'top', 'left'];
+ var start = $(this).data("resizable-alsoresize"), style = {}, css = c && c.length ? c : ['width', 'height', 'top', 'left'];
$.each(css || ['width', 'height', 'top', 'left'], function(i, prop) {
- style[prop] = (start[prop] + delta[prop]) || null
+ var sum = (start[prop]||0) + (delta[prop]||0);
+ if (sum && sum >= 0)
+ style[prop] = sum || null;
});
-
$(this).css(style);
});
};
|