From 2e4badb7f3fc5811957938fa04030a1704577b95 Mon Sep 17 00:00:00 2001 From: tsauerwein Date: Wed, 19 Feb 2014 15:45:13 +0100 Subject: [PATCH] when copying properties for touch events, make sure that those properties that might be different for each `Touch` object are not copied from the touch event --- src/ol/pointer/touchsource.js | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/ol/pointer/touchsource.js b/src/ol/pointer/touchsource.js index 884ebc8672..6bb05206f1 100644 --- a/src/ol/pointer/touchsource.js +++ b/src/ol/pointer/touchsource.js @@ -219,6 +219,13 @@ ol.pointer.TouchSource.prototype.touchToPointer_ = e.isPrimary = this.isPrimaryTouch_(inTouch); e.pointerType = this.POINTER_TYPE; + // make sure that the properties that are different for + // each `Touch` object are not copied from the BrowserEvent object + e.clientX = inTouch.clientX; + e.clientY = inTouch.clientY; + e.screenX = inTouch.screenX; + e.screenY = inTouch.screenY; + return e; };