Skip to content

Commit

Permalink
added dragoverBubble support for fallback
Browse files Browse the repository at this point in the history
  • Loading branch information
owen-m1 committed Nov 28, 2018
1 parent ead5147 commit 43f7988
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions Sortable.js
Original file line number Diff line number Diff line change
Expand Up @@ -641,7 +641,6 @@

var target = document.elementFromPoint(touchEvt.clientX, touchEvt.clientY);
var parent = target;
var i = touchDragOverListeners.length;

while (target && target.shadowRoot) {
target = target.shadowRoot.elementFromPoint(touchEvt.clientX, touchEvt.clientY);
Expand All @@ -651,6 +650,7 @@
if (parent) {
do {
if (parent[expando]) {
var i = touchDragOverListeners.length;
while (i--) {
touchDragOverListeners[i]({
clientX: touchEvt.clientX,
Expand All @@ -660,7 +660,9 @@
});
}

break;
if (!this.options.dragoverBubble) {
break;
}
}

target = parent; // store last element
Expand Down

0 comments on commit 43f7988

Please sign in to comment.