diff --git a/effects/minimizeanimation/minimizeanimation.cpp b/effects/minimizeanimation/minimizeanimation.cpp index 905a64bd82..768c384e55 100644 --- a/effects/minimizeanimation/minimizeanimation.cpp +++ b/effects/minimizeanimation/minimizeanimation.cpp @@ -33,11 +33,6 @@ MinimizeAnimationEffect::MinimizeAnimationEffect() void MinimizeAnimationEffect::prePaintScreen( ScreenPrePaintData& data, int time ) { - mActiveAnimations = mTimeLineWindows.count(); - if( mActiveAnimations > 0 ) - // We need to mark the screen windows as transformed. Otherwise the - // whole screen won't be repainted, resulting in artefacts - data.mask |= PAINT_SCREEN_WITH_TRANSFORMED_WINDOWS; QHash< EffectWindow*, TimeLine >::iterator entry = mTimeLineWindows.begin(); bool erase = false; @@ -60,6 +55,12 @@ void MinimizeAnimationEffect::prePaintScreen( ScreenPrePaintData& data, int time ++entry; } + mActiveAnimations = mTimeLineWindows.count(); + if( mActiveAnimations > 0 ) + // We need to mark the screen windows as transformed. Otherwise the + // whole screen won't be repainted, resulting in artefacts + data.mask |= PAINT_SCREEN_WITH_TRANSFORMED_WINDOWS; + effects->prePaintScreen(data, time); }