Cleanup left over code from animation changes

This commit is contained in:
bartvde
2017-03-02 13:34:49 +01:00
parent b456250cbe
commit 3d18b54978

View File

@@ -120,16 +120,8 @@ ol.control.Rotate.prototype.resetNorth_ = function() {
// upon it
return;
}
var currentRotation = view.getRotation();
if (currentRotation !== undefined) {
if (view.getRotation() !== undefined) {
if (this.duration_ > 0) {
currentRotation = currentRotation % (2 * Math.PI);
if (currentRotation < -Math.PI) {
currentRotation += 2 * Math.PI;
}
if (currentRotation > Math.PI) {
currentRotation -= 2 * Math.PI;
}
view.animate({
rotation: 0,
duration: this.duration_,