Use ol.View2D#rotate in Interaction

This commit is contained in:
Éric Lemoine
2014-02-27 10:36:36 +01:00
committed by Frederic Junod
parent 59c3857afd
commit 42adc23e86

View File

@@ -128,11 +128,7 @@ ol.interaction.Interaction.rotateWithoutConstraints =
}
}
goog.asserts.assertInstanceof(view, ol.View2D);
if (goog.isDefAndNotNull(opt_anchor)) {
var center = view.calculateCenterRotate(rotation, opt_anchor);
view.setCenter(center);
}
view.setRotation(rotation);
view.rotate(rotation, opt_anchor);
}
};