diff --git a/src/ol/view2d.js b/src/ol/view2d.js index 0f3d3474c9..8772f363ca 100644 --- a/src/ol/view2d.js +++ b/src/ol/view2d.js @@ -262,6 +262,16 @@ goog.exportProperty( */ ol.View2D.prototype.rotate = function(map, rotation, opt_anchor) { rotation = this.constraints_.rotation(rotation, 0); + this.rotateNoConstraint(map, rotation, opt_anchor); +}; + + +/** + * @param {ol.Map} map Map. + * @param {number|undefined} rotation Rotation. + * @param {ol.Coordinate=} opt_anchor Anchor coordinate. + */ +ol.View2D.prototype.rotateNoConstraint = function(map, rotation, opt_anchor) { if (goog.isDefAndNotNull(opt_anchor)) { var anchor = opt_anchor; var oldCenter = /** @type {!ol.Coordinate} */ (this.getCenter());