copy properties for pointer event from internal browser event, not from google.event.BrowserEvent
This commit is contained in:
@@ -113,7 +113,7 @@ ol.pointer.MouseSource.prototype.isEventSimulatedFromTouch_ =
|
||||
* @return {Object}
|
||||
*/
|
||||
ol.pointer.MouseSource.prototype.prepareEvent_ = function(inEvent) {
|
||||
var e = this.dispatcher.cloneEvent(inEvent);
|
||||
var e = this.dispatcher.cloneEvent(inEvent.getBrowserEvent());
|
||||
|
||||
// forward mouse preventDefault
|
||||
var pd = e.preventDefault;
|
||||
|
||||
@@ -111,7 +111,7 @@ ol.pointer.MsSource.prototype.hasBitmapType = function() {
|
||||
ol.pointer.MsSource.prototype.prepareEvent_ = function(inEvent) {
|
||||
var e = inEvent;
|
||||
if (this.HAS_BITMAP_TYPE) {
|
||||
e = this.dispatcher.cloneEvent(inEvent);
|
||||
e = this.dispatcher.cloneEvent(inEvent.getBrowserEvent());
|
||||
e.pointerType = this.POINTER_TYPES[inEvent.pointerType];
|
||||
}
|
||||
|
||||
|
||||
@@ -260,7 +260,7 @@ ol.pointer.PointerEventHandler.prototype.removeEvents_ = function(events) {
|
||||
/**
|
||||
* Returns a snapshot of inEvent, with writable properties.
|
||||
*
|
||||
* @param {goog.events.BrowserEvent|Touch} inEvent An event that contains
|
||||
* @param {Event|Touch} inEvent An event that contains
|
||||
* properties to copy.
|
||||
* @return {Object} An object containing shallow copies of
|
||||
* `inEvent`'s properties.
|
||||
|
||||
Reference in New Issue
Block a user