aboutsummaryrefslogtreecommitdiffstats
path: root/ui/ui.sortable.js
diff options
context:
space:
mode:
authorPaul Bakaus <paul.bakaus@googlemail.com>2008-11-06 11:24:34 +0000
committerPaul Bakaus <paul.bakaus@googlemail.com>2008-11-06 11:24:34 +0000
commit2619fc8073074f3de84559a3a0ae8c5076664aa9 (patch)
tree430ce455c2e2c8b4bb3dbe1835e83c417cc5e84a /ui/ui.sortable.js
parentb420cbb3ce9b5c1910ff41a65613e33463f88cd7 (diff)
downloadjquery-ui-2619fc8073074f3de84559a3a0ae8c5076664aa9.tar.gz
jquery-ui-2619fc8073074f3de84559a3a0ae8c5076664aa9.zip
sortable: returning false in any callback will now call this.cancenl() to cancel the ongoing action
Diffstat (limited to 'ui/ui.sortable.js')
-rw-r--r--ui/ui.sortable.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/ui/ui.sortable.js b/ui/ui.sortable.js
index d2a185a15..f49596c23 100644
--- a/ui/ui.sortable.js
+++ b/ui/ui.sortable.js
@@ -104,7 +104,8 @@ $.widget("ui.sortable", $.extend({}, $.ui.mouse, {
_propagate: function(n,e,inst, noPropagation) {
$.ui.plugin.call(this, n, [e, this._ui(inst)]);
- if(!noPropagation) this.element.triggerHandler(n == "sort" ? n : "sort"+n, [e, this._ui(inst)], this.options[n]);
+ var dontCancel = !noPropagation ? this.element.triggerHandler(n == "sort" ? n : "sort"+n, [e, this._ui(inst)], this.options[n]) : true;
+ if(dontCancel === false) this.cancel();
},
serialize: function(o) {