From d49cc078bbfa83c0088fcdaa768c47eee2342aad Mon Sep 17 00:00:00 2001 From: Lucas Murray Date: Mon, 15 Dec 2008 07:02:07 +0000 Subject: [PATCH] Fix inactive window translucency code. Also repaint the screen when the user changes any settings. BUG: 173793 svn path=/trunk/KDE/kdebase/workspace/; revision=897041 --- effects/maketransparent.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/effects/maketransparent.cpp b/effects/maketransparent.cpp index 96e0436bf9..dc0a9db583 100644 --- a/effects/maketransparent.cpp +++ b/effects/maketransparent.cpp @@ -62,6 +62,9 @@ void MakeTransparentEffect::reconfigure( ReconfigureFlags ) moveresize_timeline.setDuration( animationTime( conf, "Duration", 800 ) ); activeinactive_timeline.setCurveShape( TimeLine::EaseInOutCurve ); activeinactive_timeline.setDuration( animationTime( conf, "Duration", 800 ) ); + + // Repaint the screen just in case the user changed the inactive opacity + effects->addRepaintFull(); } void MakeTransparentEffect::prePaintWindow( EffectWindow* w, WindowPrePaintData& data, int time ) @@ -75,6 +78,8 @@ void MakeTransparentEffect::prePaintWindow( EffectWindow* w, WindowPrePaintData& // don't clear PAINT_WINDOW_OPAQUE, contents are not affected data.clip &= w->contentsRect().translated( w->pos()); // decoration cannot clip } + if( inactive != 1.0 && isInactive( w )) + data.setTranslucent(); if(( moveresize != 1.0 && ( w->isUserMove() || w->isUserResize())) || ( dialogs != 1.0 && w->isDialog())) {