Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Revert "Sortable: Always set placeholder size when necessary. Fixes #…
…8262 - jQuery UI 1.8.19 don't respect forcePlaceholderSize."

This reverts commit 4f19289.
(cherry picked from commit 21df5c2)
  • Loading branch information
scottgonzalez committed Apr 30, 2012
1 parent 42041f8 commit 3752211
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions ui/jquery.ui.sortable.js
Expand Up @@ -674,8 +674,9 @@ $.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;

p.height(self.currentItem.height());
p.width(self.currentItem.width());
//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)); };
}
};
}
Expand Down

0 comments on commit 3752211

Please sign in to comment.