Compositing settings have to be read if compositing is enforced by the environment variable.

BUG: 231851

svn path=/trunk/KDE/kdebase/workspace/; revision=1109536
icc-effect-5.14.5
Martin Gräßlin 2010-03-31 12:29:04 +00:00
parent fefa3a5d2f
commit bf4a2c00d9
1 changed files with 9 additions and 1 deletions

View File

@ -228,7 +228,15 @@ void Options::reloadCompositingSettings()
KConfigGroup config(_config, "Compositing");
// do not even detect compositing preferences if explicitly disabled
if( config.hasKey( "Enabled" ) && !config.readEntry( "Enabled", true ))
bool environmentForce = false;
if( getenv( "KWIN_COMPOSE" ))
{
// if compositing is enforced by the environment variable, the preferences have to be read
const char c = getenv( "KWIN_COMPOSE" )[ 0 ];
if( c == 'X' || c == 'O' )
environmentForce = true;
}
if( config.hasKey( "Enabled" ) && !config.readEntry( "Enabled", true ) && !environmentForce )
{
useCompositing = false;
return;