Remove private static members from DragRotate interaction
This commit is contained in:
@@ -27,9 +27,9 @@ const DragRotate = function(opt_options) {
|
|||||||
const options = opt_options ? opt_options : {};
|
const options = opt_options ? opt_options : {};
|
||||||
|
|
||||||
PointerInteraction.call(this, {
|
PointerInteraction.call(this, {
|
||||||
handleDownEvent: DragRotate.handleDownEvent_,
|
handleDownEvent: handleDownEvent,
|
||||||
handleDragEvent: DragRotate.handleDragEvent_,
|
handleDragEvent: handleDragEvent,
|
||||||
handleUpEvent: DragRotate.handleUpEvent_
|
handleUpEvent: handleUpEvent
|
||||||
});
|
});
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -57,9 +57,8 @@ inherits(DragRotate, PointerInteraction);
|
|||||||
/**
|
/**
|
||||||
* @param {ol.MapBrowserPointerEvent} mapBrowserEvent Event.
|
* @param {ol.MapBrowserPointerEvent} mapBrowserEvent Event.
|
||||||
* @this {ol.interaction.DragRotate}
|
* @this {ol.interaction.DragRotate}
|
||||||
* @private
|
|
||||||
*/
|
*/
|
||||||
DragRotate.handleDragEvent_ = function(mapBrowserEvent) {
|
function handleDragEvent(mapBrowserEvent) {
|
||||||
if (!mouseOnly(mapBrowserEvent)) {
|
if (!mouseOnly(mapBrowserEvent)) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@@ -80,16 +79,15 @@ DragRotate.handleDragEvent_ = function(mapBrowserEvent) {
|
|||||||
view, rotation - delta);
|
view, rotation - delta);
|
||||||
}
|
}
|
||||||
this.lastAngle_ = theta;
|
this.lastAngle_ = theta;
|
||||||
};
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param {ol.MapBrowserPointerEvent} mapBrowserEvent Event.
|
* @param {ol.MapBrowserPointerEvent} mapBrowserEvent Event.
|
||||||
* @return {boolean} Stop drag sequence?
|
* @return {boolean} Stop drag sequence?
|
||||||
* @this {ol.interaction.DragRotate}
|
* @this {ol.interaction.DragRotate}
|
||||||
* @private
|
|
||||||
*/
|
*/
|
||||||
DragRotate.handleUpEvent_ = function(mapBrowserEvent) {
|
function handleUpEvent(mapBrowserEvent) {
|
||||||
if (!mouseOnly(mapBrowserEvent)) {
|
if (!mouseOnly(mapBrowserEvent)) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
@@ -101,16 +99,15 @@ DragRotate.handleUpEvent_ = function(mapBrowserEvent) {
|
|||||||
Interaction.rotate(view, rotation,
|
Interaction.rotate(view, rotation,
|
||||||
undefined, this.duration_);
|
undefined, this.duration_);
|
||||||
return false;
|
return false;
|
||||||
};
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param {ol.MapBrowserPointerEvent} mapBrowserEvent Event.
|
* @param {ol.MapBrowserPointerEvent} mapBrowserEvent Event.
|
||||||
* @return {boolean} Start drag sequence?
|
* @return {boolean} Start drag sequence?
|
||||||
* @this {ol.interaction.DragRotate}
|
* @this {ol.interaction.DragRotate}
|
||||||
* @private
|
|
||||||
*/
|
*/
|
||||||
DragRotate.handleDownEvent_ = function(mapBrowserEvent) {
|
function handleDownEvent(mapBrowserEvent) {
|
||||||
if (!mouseOnly(mapBrowserEvent)) {
|
if (!mouseOnly(mapBrowserEvent)) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@@ -123,7 +120,7 @@ DragRotate.handleDownEvent_ = function(mapBrowserEvent) {
|
|||||||
} else {
|
} else {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
};
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Reference in New Issue
Block a user