Move CLONE_PROPS to ol.pointer.PointerEventHandler
This commit is contained in:
@@ -205,9 +205,9 @@ ol.pointer.PointerEventHandler.prototype.removeEvents_ = function(events) {
|
||||
*/
|
||||
ol.pointer.PointerEventHandler.prototype.cloneEvent = function(event, inEvent) {
|
||||
var eventCopy = {}, p;
|
||||
for (var i = 0, ii = ol.pointer.CLONE_PROPS.length; i < ii; i++) {
|
||||
p = ol.pointer.CLONE_PROPS[i][0];
|
||||
eventCopy[p] = event[p] || inEvent[p] || ol.pointer.CLONE_PROPS[i][1];
|
||||
for (var i = 0, ii = ol.pointer.PointerEventHandler.CLONE_PROPS.length; i < ii; i++) {
|
||||
p = ol.pointer.PointerEventHandler.CLONE_PROPS[i][0];
|
||||
eventCopy[p] = event[p] || inEvent[p] || ol.pointer.PointerEventHandler.CLONE_PROPS[i][1];
|
||||
}
|
||||
|
||||
return eventCopy;
|
||||
@@ -407,7 +407,7 @@ ol.pointer.PointerEventHandler.prototype.disposeInternal = function() {
|
||||
* Properties to copy when cloning an event, with default values.
|
||||
* @type {Array.<Array>}
|
||||
*/
|
||||
ol.pointer.CLONE_PROPS = [
|
||||
ol.pointer.PointerEventHandler.CLONE_PROPS = [
|
||||
// MouseEvent
|
||||
['bubbles', false],
|
||||
['cancelable', false],
|
||||
|
||||
Reference in New Issue
Block a user