Skip to content

dnd: Skip drag target when its acceptDrop() throws an exception

In the case of bugs in a drag target's acceptDrop() function, it may throw an exception. In the previous code, this would break out of the loop entirely and never cancel the drag, so the mouse button release event would be ignored and you would have to press Esc to get out of the drag.

In this change, if acceptDrop() throws an exception, we log it and move on to the next parent target instead.

Merge request reports