mirror of
https://github.com/jquery/jquery-ui.git
synced 2025-01-07 20:34:24 +00:00
sortable: returning false in any callback will now call this.cancenl() to cancel the ongoing action
This commit is contained in:
parent
b420cbb3ce
commit
2619fc8073
@ -104,7 +104,8 @@ $.widget("ui.sortable", $.extend({}, $.ui.mouse, {
|
|||||||
|
|
||||||
_propagate: function(n,e,inst, noPropagation) {
|
_propagate: function(n,e,inst, noPropagation) {
|
||||||
$.ui.plugin.call(this, n, [e, this._ui(inst)]);
|
$.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) {
|
serialize: function(o) {
|
||||||
|
Loading…
Reference in New Issue
Block a user