diff options
author | wout <wout@impinc.co.uk> | 2013-03-24 19:19:06 +0100 |
---|---|---|
committer | wout <wout@impinc.co.uk> | 2013-03-24 19:19:06 +0100 |
commit | 67d367e0d74b3287956130da0077e42c6483dd2f (patch) | |
tree | bb2d23315e39c89b79cb8c52e7a5db54636e08ad /src/gradient.js | |
parent | ff09596144c3fd6770d1dc64178a10c2432396ca (diff) | |
download | svg.js-67d367e0d74b3287956130da0077e42c6483dd2f.tar.gz svg.js-67d367e0d74b3287956130da0077e42c6483dd2f.zip |
Bumped to v0.11
- removed SVG.Wrap on SVG.Polyline, SVG.Polygon and SVG.Path
- added delay on SVG.FX module
- made x(), y(), cx() and cy() as getters
- added SGB.get() method, to get elements by a DOM id
- fixed bug in remove() method on container elements
- added jasmine test suite to repo
Diffstat (limited to 'src/gradient.js')
-rw-r--r-- | src/gradient.js | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/gradient.js b/src/gradient.js index 4c30b43..6a2155e 100644 --- a/src/gradient.js +++ b/src/gradient.js @@ -52,8 +52,7 @@ SVG.extend(SVG.Gradient, { // SVG.extend(SVG.Defs, { - - /* define gradient */ + // define gradient gradient: function(type, block) { var element = this.put(new SVG.Gradient(type)) @@ -78,8 +77,7 @@ SVG.Stop.prototype = new SVG.Element() // SVG.extend(SVG.Stop, { - - /* add color stops */ + // add color stops update: function(o) { var index , attr = ['opacity', 'color'] @@ -90,7 +88,7 @@ SVG.extend(SVG.Stop, { this.style('stop-' + attr[index], o[attr[index]]) /* set attributes */ - return this.attr('offset', (o.offset != null ? o.offset : this.attrs.offset || 0) + '%') + return this.attr('offset', (o.offset != null ? o.offset : this.attr('offset')) + '%') } }) |