diff options
Diffstat (limited to 'src/gui/effects')
-rw-r--r-- | src/gui/effects/qgraphicseffect.cpp | 8 | ||||
-rw-r--r-- | src/gui/effects/qgraphicseffect_p.h | 2 |
2 files changed, 7 insertions, 3 deletions
diff --git a/src/gui/effects/qgraphicseffect.cpp b/src/gui/effects/qgraphicseffect.cpp index e25b40b..f20480b 100644 --- a/src/gui/effects/qgraphicseffect.cpp +++ b/src/gui/effects/qgraphicseffect.cpp @@ -350,8 +350,10 @@ void QGraphicsEffect::setEnabled(bool enable) return; d->isEnabled = enable; - if (d->source) + if (d->source) { d->source->d_func()->effectBoundingRectChanged(); + d->source->d_func()->invalidateCache(); + } emit enabledChanged(enable); } @@ -405,8 +407,10 @@ QGraphicsEffectSource *QGraphicsEffect::source() const void QGraphicsEffect::updateBoundingRect() { Q_D(QGraphicsEffect); - if (d->source) + if (d->source) { d->source->d_func()->effectBoundingRectChanged(); + d->source->d_func()->invalidateCache(); + } } /*! diff --git a/src/gui/effects/qgraphicseffect_p.h b/src/gui/effects/qgraphicseffect_p.h index 87abbbc..24d8696 100644 --- a/src/gui/effects/qgraphicseffect_p.h +++ b/src/gui/effects/qgraphicseffect_p.h @@ -102,8 +102,8 @@ public: QGraphicsEffect::ChangeFlags flags; if (source) { flags |= QGraphicsEffect::SourceDetached; - source->d_func()->detach(); source->d_func()->invalidateCache(); + source->d_func()->detach(); delete source; } source = newSource; |