diff options
author | Scott González <scott.gonzalez@gmail.com> | 2011-05-27 12:29:28 -0700 |
---|---|---|
committer | Scott González <scott.gonzalez@gmail.com> | 2011-05-27 12:29:28 -0700 |
commit | 12f73d623e54a37cc347f48db4c7dea23648ba1e (patch) | |
tree | e36765313a215546b56c54c171d1d8cf27e33a55 /ui/jquery.ui.draggable.js | |
parent | 8a972f5cce2b84a431a700201cdf649edd2f4ac7 (diff) | |
parent | 67bd872fe1f8c4763d646f4eca852777e6f7a126 (diff) | |
download | jquery-ui-12f73d623e54a37cc347f48db4c7dea23648ba1e.tar.gz jquery-ui-12f73d623e54a37cc347f48db4c7dea23648ba1e.zip |
Merge pull request #352 from kborchers/bug_5003_3
Droppable: Added dragStart and dragStop to ddmanager and call them from draggable to recalculate droppable positions after a drag causes a scroll. Fixes #5003 - Scroll on Droppable Demo Breaks Demo
Diffstat (limited to 'ui/jquery.ui.draggable.js')
-rw-r--r-- | ui/jquery.ui.draggable.js | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/ui/jquery.ui.draggable.js b/ui/jquery.ui.draggable.js index c16833eb0..f8c187a7a 100644 --- a/ui/jquery.ui.draggable.js +++ b/ui/jquery.ui.draggable.js @@ -163,6 +163,10 @@ $.widget("ui.draggable", $.ui.mouse, { this.helper.addClass("ui-draggable-dragging"); this._mouseDrag(event, true); //Execute the drag once - this causes the helper not to be visible before getting its correct position + + //If the ddmanager is used for droppables, inform the manager that dragging has started (see #5003) + if ( $.ui.ddmanager ) $.ui.ddmanager.dragStart(this, event); + return true; }, @@ -229,6 +233,9 @@ $.widget("ui.draggable", $.ui.mouse, { }); //Remove frame helpers } + //If the ddmanager is used for droppables, inform the manager that dragging has stopped (see #5003) + if( $.ui.ddmanager ) $.ui.ddmanager.dragStop(this, event); + return $.ui.mouse.prototype._mouseUp.call(this, event); }, |