Skip to content

Commit aca3a25

Browse files
committed
#1431: Remove pointercancel; #985: remove dropEffect
1 parent 41e3394 commit aca3a25

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

Sortable.js

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -617,7 +617,6 @@
617617

618618
_onTapStart: function (/** Event|TouchEvent */evt) {
619619
if (!evt.cancelable) return;
620-
621620
var _this = this,
622621
el = this.el,
623622
options = this.options,
@@ -808,7 +807,6 @@
808807

809808
if (options.supportPointer) {
810809
_on(ownerDocument, 'pointerup', _this._onDrop);
811-
_on(ownerDocument, 'pointercancel', _this._onDrop);
812810
} else {
813811
_on(ownerDocument, 'mouseup', _this._onDrop);
814812
_on(ownerDocument, 'touchend', _this._onDrop);
@@ -1061,7 +1059,6 @@
10611059
_off(document, 'mouseup', _this._onDrop);
10621060
_off(document, 'touchend', _this._onDrop);
10631061
_off(document, 'touchcancel', _this._onDrop);
1064-
_off(document, 'pointercancel', _this._onDrop);
10651062

10661063
if (dataTransfer) {
10671064
dataTransfer.effectAllowed = 'move';
@@ -1365,14 +1362,12 @@
13651362
_off(ownerDocument, 'touchend', this._onDrop);
13661363
_off(ownerDocument, 'pointerup', this._onDrop);
13671364
_off(ownerDocument, 'touchcancel', this._onDrop);
1368-
_off(ownerDocument, 'pointercancel', this._onDrop);
13691365
_off(document, 'selectstart', this);
13701366
},
13711367

13721368
_onDrop: function (/**Event*/evt) {
13731369
var el = this.el,
13741370
options = this.options;
1375-
13761371
awaitingDragStarted = false;
13771372
scrolling = false;
13781373
isCircumstantialInvert = false;
@@ -1718,7 +1713,7 @@
17181713

17191714
function _globalDragOver(/**Event*/evt) {
17201715
if (evt.dataTransfer) {
1721-
evt.dataTransfer.dropEffect = 'move';
1716+
evt.dataTransfer.dropEffect = 'none';
17221717
}
17231718
evt.cancelable && evt.preventDefault();
17241719
}

0 commit comments

Comments
 (0)