mirror of
https://github.com/openseadragon/openseadragon.git
synced 2024-11-25 06:36:11 +03:00
removeContact only on existing tracked pointer
This commit is contained in:
parent
7fbff2cc27
commit
72fc528b3c
@ -3281,11 +3281,13 @@
|
|||||||
|
|
||||||
gPoint = updateGPoint;
|
gPoint = updateGPoint;
|
||||||
} else {
|
} else {
|
||||||
// Initialize for tracking and add to the tracking list (no pointerover or pointermove event occurred before this)
|
// Initialize for tracking and add to the tracking list (no pointerenter event occurred before this)
|
||||||
|
$.console.warn('pointerdown event on untracked pointer');
|
||||||
gPoint.captured = false; // Handled by updatePointerCaptured()
|
gPoint.captured = false; // Handled by updatePointerCaptured()
|
||||||
gPoint.insideElementPressed = true;
|
gPoint.insideElementPressed = true;
|
||||||
gPoint.insideElement = true;
|
gPoint.insideElement = true;
|
||||||
startTrackingPointer( pointsList, gPoint );
|
startTrackingPointer( pointsList, gPoint );
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
pointsList.addContact();
|
pointsList.addContact();
|
||||||
@ -3410,6 +3412,9 @@
|
|||||||
updateGPoint = pointsList.getById( gPoint.id );
|
updateGPoint = pointsList.getById( gPoint.id );
|
||||||
|
|
||||||
if ( updateGPoint ) {
|
if ( updateGPoint ) {
|
||||||
|
pointsList.removeContact();
|
||||||
|
//$.console.log('contacts-- ', pointsList.contacts);
|
||||||
|
|
||||||
// Update the pointer, stop tracking it if not still in this element
|
// Update the pointer, stop tracking it if not still in this element
|
||||||
if ( updateGPoint.captured ) {
|
if ( updateGPoint.captured ) {
|
||||||
//updateGPoint.captured = false; // Handled by updatePointerCaptured()
|
//updateGPoint.captured = false; // Handled by updatePointerCaptured()
|
||||||
@ -3436,9 +3441,6 @@
|
|||||||
updateGPoint = gPoint;
|
updateGPoint = gPoint;
|
||||||
}
|
}
|
||||||
|
|
||||||
pointsList.removeContact();
|
|
||||||
//$.console.log('contacts-- ', pointsList.contacts);
|
|
||||||
|
|
||||||
if ( !eventInfo.preventGesture && !eventInfo.defaultPrevented ) {
|
if ( !eventInfo.preventGesture && !eventInfo.defaultPrevented ) {
|
||||||
if ( wasCaptured ) {
|
if ( wasCaptured ) {
|
||||||
// Pointer was activated in our element but could have been removed in any element since events are captured to our element
|
// Pointer was activated in our element but could have been removed in any element since events are captured to our element
|
||||||
|
Loading…
Reference in New Issue
Block a user