Skip to content

Commit

Permalink
Fixes upper bound calculation.
Browse files Browse the repository at this point in the history
  • Loading branch information
jeremyckahn committed Feb 23, 2014
1 parent 81d6453 commit 4275bcd
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/jquery.dragon.js
Expand Up @@ -261,16 +261,16 @@

var maxLeft = containerOffset.left
+ $container.outerWidth()
- parseInt($container.css('border-left-width'), 10)
- parseInt($container.css('padding-left'), 10)
- parseInt($container.css('border-right-width'), 10)
- parseInt($container.css('padding-right'), 10)
+ parseInt($el.css('margin-left'), 10)
+ parseInt($el.css('margin-right'), 10)
- $el.outerWidth(true);

var maxTop = containerOffset.top
+ $container.outerHeight()
- parseInt($container.css('border-top-width'), 10)
- parseInt($container.css('padding-top'), 10)
- parseInt($container.css('border-bottom-width'), 10)
- parseInt($container.css('padding-bottom'), 10)
+ parseInt($el.css('margin-top'), 10)
+ parseInt($el.css('margin-bottom'), 10)
- $el.outerHeight(true);
Expand Down

0 comments on commit 4275bcd

Please sign in to comment.