summaryrefslogtreecommitdiffstats
path: root/dist/svg.js
diff options
context:
space:
mode:
authorwout <wout@impinc.co.uk>2014-09-03 15:39:47 +0200
committerwout <wout@impinc.co.uk>2014-09-03 15:39:47 +0200
commit2649e3153e82f840365ce26564be96e0385199ce (patch)
tree0b3657a2ada0887e9bb0945e4d703abbf63200eb /dist/svg.js
parent17e15d57d8eb2cb20cc72abcf1bd5bb1bbd39e49 (diff)
downloadsvg.js-2649e3153e82f840365ce26564be96e0385199ce.tar.gz
svg.js-2649e3153e82f840365ce26564be96e0385199ce.zip
Fix in SVG.Number
Diffstat (limited to 'dist/svg.js')
-rwxr-xr-xdist/svg.js10
1 files changed, 6 insertions, 4 deletions
diff --git a/dist/svg.js b/dist/svg.js
index 088fc18..8aa70d3 100755
--- a/dist/svg.js
+++ b/dist/svg.js
@@ -6,7 +6,7 @@
* @copyright Wout Fierens <wout@impinc.co.uk>
* @license MIT
*
-* BUILT: Wed Sep 03 2014 15:23:40 GMT+0200 (CEST)
+* BUILT: Wed Sep 03 2014 15:38:51 GMT+0200 (CEST)
*/;
(function(root, factory) {
@@ -774,7 +774,7 @@ SVG.Number = SVG.invent({
} else {
if (value instanceof SVG.Number) {
- this.value = value.value
+ this.value = value.valueOf()
this.unit = value.unit
}
}
@@ -814,10 +814,12 @@ SVG.Number = SVG.invent({
}
// Convert to different unit
, to: function(unit) {
+ var number = new SVG.Number(this)
+
if (typeof unit === 'string')
- this.unit = unit
+ number.unit = unit
- return this
+ return number
}
// Make number morphable
, morph: function(number) {