diff options
author | wout <wout@impinc.co.uk> | 2012-12-21 19:58:49 +0100 |
---|---|---|
committer | wout <wout@impinc.co.uk> | 2012-12-21 19:58:49 +0100 |
commit | 9dd851e68a3241883dea7236da48d4878b1b1899 (patch) | |
tree | 0da2a3ab4c8fab04228967f354e99f4a3027fad7 /src/element.js | |
parent | 34a2a1ad00c96f3ef222a08ff5516b2067f7af87 (diff) | |
download | svg.js-9dd851e68a3241883dea7236da48d4878b1b1899.tar.gz svg.js-9dd851e68a3241883dea7236da48d4878b1b1899.zip |
Cross browser fixes
Diffstat (limited to 'src/element.js')
-rw-r--r-- | src/element.js | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/src/element.js b/src/element.js index 981f9a0..5664f46 100644 --- a/src/element.js +++ b/src/element.js @@ -50,15 +50,6 @@ SVG.extend(SVG.Element, { else return this.attrs[a]; - } else if (this._isStyle(a)) { - a == 'text' ? - this.text(v) : - a == 'leading' ? - this[a] = v : - this.style[a] = v; - - this.text(this.content); - } else { this.attrs[a] = v; if (a == 'x' && this._isText()) @@ -68,7 +59,16 @@ SVG.extend(SVG.Element, { n != null ? this.node.setAttributeNS(n, a, v) : this.node.setAttribute(a, v); - + + if (this._isStyle(a)) { + a == 'text' ? + this.text(v) : + a == 'leading' ? + this[a] = v : + this.style[a] = v; + + this.text(this.content); + } } return this; |