You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Align mouse events sequence with browsers which support native dnd #21320
In Safari and Chrome, we can get following events when you click on a selection and dnd
mousedown
mousemove, mousemove ... (the number of mousemove events depend on how fast you move)
dragstart
drag, dragover
drag, dragenter, dragover
...
drag, dragover
drop
dragend
However right now, we are implementing our dnd by listening to mousedown and mouse up events, our emitted events are like
drag
mousedown
drop
drag
...
drag
mouseup
drop
Moreover, single click on a selection now emits redundant events
drag
mousedown
mouseup
This is because whenever users click on a selection, right now we think it's a drag event but if users release the mouse real quick (we get a mosueup event from browser before a mouse move event kicks in), we will treat it as a single click. But since we take it as drag at the beginning, we emit an unnecessary drag event.
Activity
rebornix commentedon Mar 29, 2017
The sequence is already sane.