diff --git a/dist/docs/assets/js/paper.js b/dist/docs/assets/js/paper.js index 1f83fd85..31ac70b4 100644 --- a/dist/docs/assets/js/paper.js +++ b/dist/docs/assets/js/paper.js @@ -9,7 +9,7 @@ * * All rights reserved. * - * Date: Tue Jan 3 13:23:44 2017 +0100 + * Date: Tue Jan 3 13:39:35 2017 +0100 * *** * @@ -3344,7 +3344,7 @@ new function() { getRotation: function() { var decomposed = this._decompose(); - return decomposed && decomposed.rotation; + return decomposed ? decomposed.rotation : 0; }, setRotation: function(rotation) { @@ -3352,17 +3352,17 @@ new function() { if (current != null && rotation != null) { var decomposed = this._decomposed; this.rotate(rotation - current); - decomposed.rotation = rotation; - this._decomposed = decomposed; + if (decomposed) { + decomposed.rotation = rotation; + this._decomposed = decomposed; + } } }, getScaling: function() { var decomposed = this._decompose(), - scaling = decomposed && decomposed.scaling; - return scaling - ? new LinkedPoint(scaling.x, scaling.y, this, 'setScaling') - : undefined; + s = decomposed && decomposed.scaling; + return new LinkedPoint(s ? s.x : 1, s ? s.y : 1, this, 'setScaling'); }, setScaling: function() { @@ -3371,8 +3371,10 @@ new function() { if (current && scaling && !current.equals(scaling)) { var decomposed = this._decomposed; this.scale(scaling.x / current.x, scaling.y / current.y); - decomposed.scaling = scaling; - this._decomposed = decomposed; + if (decomposed) { + decomposed.scaling = scaling; + this._decomposed = decomposed; + } } }, diff --git a/dist/docs/classes/CompoundPath.html b/dist/docs/classes/CompoundPath.html index c7d47cd0..fe2cad50 100644 --- a/dist/docs/classes/CompoundPath.html +++ b/dist/docs/classes/CompoundPath.html @@ -1127,7 +1127,7 @@ circle.position.x += 100;