Skip to content
Permalink
Browse files

QgsGlowEffect: add missing members in operator=() and make copy const…

…ructor use it
  • Loading branch information
rouault authored and nyalldawson committed Jan 30, 2020
1 parent 2f956b8 commit 6e67d2cfa7059cb73a0c69af130fef03a0851343
Showing with 5 additions and 14 deletions.
  1. +5 −14 src/core/effects/qgsgloweffect.cpp
@@ -29,21 +29,8 @@ QgsGlowEffect::QgsGlowEffect()

QgsGlowEffect::QgsGlowEffect( const QgsGlowEffect &other )
: QgsPaintEffect( other )
, mSpread( other.spread() )
, mSpreadUnit( other.spreadUnit() )
, mSpreadMapUnitScale( other.spreadMapUnitScale() )
, mBlurLevel( other.blurLevel() )
, mBlurUnit( other.mBlurUnit )
, mBlurMapUnitScale( other.mBlurMapUnitScale )
, mOpacity( other.opacity() )
, mColor( other.color() )
, mBlendMode( other.blendMode() )
, mColorType( other.colorType() )
{
if ( other.ramp() )
{
mRamp = other.ramp()->clone();
}
operator=( other );
}

QgsGlowEffect::~QgsGlowEffect()
@@ -216,8 +203,12 @@ QgsGlowEffect &QgsGlowEffect::operator=( const QgsGlowEffect &rhs )
delete mRamp;

mSpread = rhs.spread();
mSpreadUnit = rhs.spreadUnit();
mSpreadMapUnitScale = rhs.spreadMapUnitScale();
mRamp = rhs.ramp() ? rhs.ramp()->clone() : nullptr;
mBlurLevel = rhs.blurLevel();
mBlurUnit = rhs.mBlurUnit;
mBlurMapUnitScale = rhs.mBlurMapUnitScale;
mOpacity = rhs.opacity();
mColor = rhs.color();
mBlendMode = rhs.blendMode();

0 comments on commit 6e67d2c

Please sign in to comment.
You can’t perform that action at this time.