summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorUlrich-Matthias Schäfer <ulima.ums@googlemail.com>2016-04-09 18:06:24 +0200
committerUlrich-Matthias Schäfer <ulima.ums@googlemail.com>2016-04-09 18:06:24 +0200
commit700a77060fe2b347e256abdb423c75a05613a690 (patch)
tree2454b9cf3b0dbb855741c58677c8ae31545b0a4c /src
parent8bdc17f571d428a62afaf5853679378047b5aafd (diff)
downloadsvg.js-700a77060fe2b347e256abdb423c75a05613a690.tar.gz
svg.js-700a77060fe2b347e256abdb423c75a05613a690.zip
fixed old target references
Diffstat (limited to 'src')
-rw-r--r--src/gradient.js4
-rw-r--r--src/sugar.js4
2 files changed, 4 insertions, 4 deletions
diff --git a/src/gradient.js b/src/gradient.js
index 9478747..17145e6 100644
--- a/src/gradient.js
+++ b/src/gradient.js
@@ -55,13 +55,13 @@ SVG.Gradient = SVG.invent({
SVG.extend(SVG.Gradient, SVG.FX, {
// From position
from: function(x, y) {
- return (this.target || this).type == 'radial' ?
+ return (this._target || this).type == 'radial' ?
this.attr({ fx: new SVG.Number(x), fy: new SVG.Number(y) }) :
this.attr({ x1: new SVG.Number(x), y1: new SVG.Number(y) })
}
// To position
, to: function(x, y) {
- return (this.target || this).type == 'radial' ?
+ return (this._target || this).type == 'radial' ?
this.attr({ cx: new SVG.Number(x), cy: new SVG.Number(y) }) :
this.attr({ x2: new SVG.Number(x), y2: new SVG.Number(y) })
}
diff --git a/src/sugar.js b/src/sugar.js
index 6e1bbf4..7db5ce6 100644
--- a/src/sugar.js
+++ b/src/sugar.js
@@ -76,9 +76,9 @@ SVG.extend(SVG.Element, SVG.FX, {
SVG.extend(SVG.Rect, SVG.Ellipse, SVG.Circle, SVG.Gradient, SVG.FX, {
// Add x and y radius
radius: function(x, y) {
- var type = (this.target || this).type;
+ var type = (this._target || this).type;
return type == 'radial' || type == 'circle' ?
- this.attr({ 'r': new SVG.Number(x) }) :
+ this.attr('r', new SVG.Number(x)) :
this.rx(x).ry(y == null ? x : y)
}
})