Do not prevent default on pointermove

Instead, only prevent default on handled pointerdown events. This makes 
the `focus` condition work with interactions that involve dragging on 
touch devices.
This commit is contained in:
ahocevar
2018-07-31 08:33:15 +02:00
parent a56ca57ac6
commit c74b9c1d55
7 changed files with 58 additions and 5 deletions

View File

@@ -223,6 +223,9 @@ export function handleEvent(mapBrowserEvent) {
} else {
if (mapBrowserEvent.type == MapBrowserEventType.POINTERDOWN) {
const handled = this.handleDownEvent_(mapBrowserEvent);
if (handled) {
mapBrowserEvent.preventDefault();
}
this.handlingDownUpSequence = handled;
stopEvent = this.stopDown(handled);
} else if (mapBrowserEvent.type == MapBrowserEventType.POINTERMOVE) {