aboutsummaryrefslogtreecommitdiffstats
path: root/ui/jquery.ui.sortable.js
diff options
context:
space:
mode:
authorBertjh <bertjh@hotmail.com>2012-04-19 09:05:37 -0400
committerScott González <scott.gonzalez@gmail.com>2012-04-19 09:05:37 -0400
commit4f19289c10e733a07cf60435c2e5df4ed2e23d37 (patch)
treec928d4207d0cc5a4479d7cefb6650bd6533c51f5 /ui/jquery.ui.sortable.js
parentd0cac090278c8159a038a5c6534aeec44fa031ab (diff)
downloadjquery-ui-4f19289c10e733a07cf60435c2e5df4ed2e23d37.tar.gz
jquery-ui-4f19289c10e733a07cf60435c2e5df4ed2e23d37.zip
Sortable: Always set placeholder size when necessary. Fixes #8262 - jQuery UI 1.8.19 don't respect forcePlaceholderSize.
Diffstat (limited to 'ui/jquery.ui.sortable.js')
-rw-r--r--ui/jquery.ui.sortable.js5
1 files changed, 2 insertions, 3 deletions
diff --git a/ui/jquery.ui.sortable.js b/ui/jquery.ui.sortable.js
index 2813b5681..5373967df 100644
--- a/ui/jquery.ui.sortable.js
+++ b/ui/jquery.ui.sortable.js
@@ -673,9 +673,8 @@ $.widget("ui.sortable", $.ui.mouse, {
// 2. The option 'forcePlaceholderSize can be enabled to force it even if a class name is specified
if(className && !o.forcePlaceholderSize) return;
- //If the element doesn't have a actual height by itself (without styles coming from a stylesheet), it receives the inline height from the dragged item
- if(!p.height()) { p.height(self.currentItem.innerHeight() - parseInt(self.currentItem.css('paddingTop')||0, 10) - parseInt(self.currentItem.css('paddingBottom')||0, 10)); };
- if(!p.width()) { p.width(self.currentItem.innerWidth() - parseInt(self.currentItem.css('paddingLeft')||0, 10) - parseInt(self.currentItem.css('paddingRight')||0, 10)); };
+ p.height(self.currentItem.height());
+ p.width(self.currentItem.width());
}
};
}