Currently, it's implicitly assumed there's only a maximum of one touch active at any time, leading to unexpected behaviour when e.g. tapping with a second finger while dragging (drag is cancelled, but end event never fired).
The most simple workaround would be to simply ignore any additional touches and prevent them from interfering with the current state. This would be quite straightforward with two guards, in the start and stop handlers respectively:
Top of startHandler, after left/right mouse button test:
Currently, it's implicitly assumed there's only a maximum of one touch active at any time, leading to unexpected behaviour when e.g. tapping with a second finger while dragging (drag is cancelled, but end event never fired).
The most simple workaround would be to simply ignore any additional touches and prevent them from interfering with the current state. This would be quite straightforward with two guards, in the start and stop handlers respectively:
Top of
startHandler
, after left/right mouse button test:Top of
stopHandler
, after clearing timeout: