diff options
| author | Markus Engel <markus.engel@tum.de> | 2013-04-07 16:28:22 +0000 |
|---|---|---|
| committer | Markus Engel <markus.engel@tum.de> | 2013-04-07 16:28:22 +0000 |
| commit | 27e2102f96a5554bcd5310ec11435d155773b279 (patch) | |
| tree | e5f982c25aed199f9027a6277b17302f97b4c80c /src/sp-gradient.cpp | |
| parent | Merged FilterPrimitive and subclasses. (diff) | |
| download | inkscape-27e2102f96a5554bcd5310ec11435d155773b279.tar.gz inkscape-27e2102f96a5554bcd5310ec11435d155773b279.zip | |
Merge Object and subclasses. Merging of SP- and C-classes complete.
(bzr r11608.1.86)
Diffstat (limited to 'src/sp-gradient.cpp')
| -rw-r--r-- | src/sp-gradient.cpp | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/src/sp-gradient.cpp b/src/sp-gradient.cpp index 530e5be40..2cdf2198f 100644 --- a/src/sp-gradient.cpp +++ b/src/sp-gradient.cpp @@ -145,9 +145,6 @@ SPGradient::SPGradient() : SPPaintServer(), units(), state(2), vector() { - - this->cobject = this; - this->has_patches = 0; this->ref = new SPGradientReference(this); @@ -421,7 +418,9 @@ void SPGradient::remove_child(Inkscape::XML::Node *child) void SPGradient::modified(guint flags) { if (flags & SP_OBJECT_CHILD_MODIFIED_FLAG) { - if( this->get_type() != SP_GRADIENT_TYPE_MESH ) { + // CPPIFY + //if( this->get_type() != SP_GRADIENT_TYPE_MESH ) { + if (!SP_IS_MESHGRADIENT(this)) { this->invalidateVector(); } else { this->invalidateArray(); @@ -429,7 +428,9 @@ void SPGradient::modified(guint flags) } if (flags & SP_OBJECT_STYLE_MODIFIED_FLAG) { - if( this->get_type() != SP_GRADIENT_TYPE_MESH ) { + // CPPIFY + //if( this->get_type() != SP_GRADIENT_TYPE_MESH ) { + if (!SP_IS_MESHGRADIENT(this)) { this->ensureVector(); } else { this->ensureArray(); @@ -1043,8 +1044,9 @@ sp_gradient_create_preview_pattern(SPGradient *gr, double width) { cairo_pattern_t *pat = NULL; - if( gr->get_type() != SP_GRADIENT_TYPE_MESH ) { - + // CPPIFY + //if( gr->get_type() != SP_GRADIENT_TYPE_MESH ) { + if (!SP_IS_MESHGRADIENT(gr)) { gr->ensureVector(); pat = cairo_pattern_create_linear(0, 0, width, 0); |
