]> source.dussan.org Git - jquery-ui.git/commitdiff
Sortable: Fixed _trigger method.
authorScott González <scott.gonzalez@gmail.com>
Fri, 16 Jan 2009 02:25:03 +0000 (02:25 +0000)
committerScott González <scott.gonzalez@gmail.com>
Fri, 16 Jan 2009 02:25:03 +0000 (02:25 +0000)
ui/ui.sortable.js

index 49387a4420e21980d5e654c2f59e90833fffb1c3..77c2678e2794d4cb966e66f4e8f0f205763cc063 100644 (file)
@@ -894,8 +894,11 @@ $.widget("ui.sortable", $.extend({}, $.ui.mouse, {
 
        _trigger: function(type, event, inst, noPropagation) {
                $.ui.plugin.call(this, type, [event, this._uiHash(inst)]);
-               if(!noPropagation) $.widget.prototype._trigger.call(this, type, event, this._uiHash(inst));
-               if(event && event.result === false) this.cancel();
+               if(!noPropagation) {
+                       if ($.widget.prototype._trigger.call(this, type, event, this._uiHash(inst)) === false) {
+                               this.cancel();
+                       }
+               }
        },
 
        plugins: {},