From 54c8beef4e827c46ed68dabc364eea0851d75662 Mon Sep 17 00:00:00 2001 From: Thomas Chandelle Date: Wed, 1 Feb 2017 13:32:02 +0100 Subject: [PATCH] Stop handling down/up sequence when all fingers have been removed --- src/ol/interaction/pointer.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/ol/interaction/pointer.js b/src/ol/interaction/pointer.js index 048ff27bf9..b96193f735 100644 --- a/src/ol/interaction/pointer.js +++ b/src/ol/interaction/pointer.js @@ -187,8 +187,8 @@ ol.interaction.Pointer.handleEvent = function(mapBrowserEvent) { if (mapBrowserEvent.type == ol.MapBrowserEventType.POINTERDRAG) { this.handleDragEvent_(mapBrowserEvent); } else if (mapBrowserEvent.type == ol.MapBrowserEventType.POINTERUP) { - this.handleUpEvent_(mapBrowserEvent); - this.handlingDownUpSequence = false; + this.handlingDownUpSequence = this.handleUpEvent_(mapBrowserEvent) && + this.targetPointers.length > 0; } } else { if (mapBrowserEvent.type == ol.MapBrowserEventType.POINTERDOWN) {