What is the diffrence between onTouchEnd and onTouchCancel?
touchMove, touchStart, touchEnd, touchCancel are part of the multi-touch sequence. A multi-touch sequence begins when a finger first touches the surface (touchStart).
- touchstart - fired when a touch point is placed on the touch surface.
- touchmove - fired when a touch point is moved along the touch surface.
- touchend - fired when a touch point is removed from the touch surface.
- touchcancel - fired when a touch point has been disrupted in an implementation-specific manner (for example, too many touch points are created).
So from what I understand, touchCancel will fire when the multi-touch sequence is being disrupted e.g. by another finger touching the surface. Whereas touchEnd will mean the sequence has been successfully completed.
Okay that’s clear! Thanks @Leonidas!