summaryrefslogtreecommitdiffstats
path: root/src/clip.js
diff options
context:
space:
mode:
authorwout <wout@impinc.co.uk>2014-06-21 18:25:29 +0200
committerwout <wout@impinc.co.uk>2014-06-21 18:25:29 +0200
commit19b6fd4338246d1fd9ca4806e57c7aebcec63826 (patch)
tree3dd1d207de9f586f7e4d4cd36917e347ab022a9e /src/clip.js
parentbb0e6be2da0cea98c5303871c0be055f5f70d7a9 (diff)
downloadsvg.js-19b6fd4338246d1fd9ca4806e57c7aebcec63826.tar.gz
svg.js-19b6fd4338246d1fd9ca4806e57c7aebcec63826.zip
Removed all structural references
Diffstat (limited to 'src/clip.js')
-rwxr-xr-xsrc/clip.js8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/clip.js b/src/clip.js
index e8a5e35..3fb5daa 100755
--- a/src/clip.js
+++ b/src/clip.js
@@ -1,4 +1,4 @@
-SVG.Clip = SVG.invent({
+SVG.ClipPath = SVG.invent({
// Initialize node
create: function() {
this.constructor.call(this, SVG.create('clipPath'))
@@ -21,7 +21,7 @@ SVG.Clip = SVG.invent({
delete this.targets
/* remove clipPath from parent */
- this.parent.removeElement(this)
+ this.parent().removeElement(this)
return this
}
@@ -31,7 +31,7 @@ SVG.Clip = SVG.invent({
, construct: {
// Create clipping element
clip: function() {
- return this.defs().put(new SVG.Clip)
+ return this.defs().put(new SVG.ClipPath)
}
}
})
@@ -41,7 +41,7 @@ SVG.extend(SVG.Element, {
// Distribute clipPath to svg element
clipWith: function(element) {
/* use given clip or create a new one */
- this.clipper = element instanceof SVG.Clip ? element : this.parent.clip().add(element)
+ this.clipper = element instanceof SVG.ClipPath ? element : this.parent().clip().add(element)
/* store reverence on self in mask */
this.clipper.targets.push(this)