From 3d18b54978bbe0670d54f6dd66ace38cbff743dd Mon Sep 17 00:00:00 2001 From: bartvde Date: Thu, 2 Mar 2017 13:34:49 +0100 Subject: [PATCH] Cleanup left over code from animation changes --- src/ol/control/rotate.js | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/src/ol/control/rotate.js b/src/ol/control/rotate.js index f083888b16..7f28097aa0 100644 --- a/src/ol/control/rotate.js +++ b/src/ol/control/rotate.js @@ -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_,