It's possible that there is no active window when activating present windows for a window class. In that case do not activate the effect.

BUG: 220916

svn path=/trunk/KDE/kdebase/workspace/; revision=1068693
This commit is contained in:
Martin Gräßlin 2010-01-01 20:45:40 +00:00
parent 061a6d7642
commit 14b7540b26

View file

@ -162,8 +162,13 @@ void* PresentWindowsEffect::proxy()
void PresentWindowsEffect::toggleActiveClass()
{
m_mode = ModeWindowClass;
m_class = effects->activeWindow()->windowClass();
if( !m_activated )
{
if( !effects->activeWindow() )
return;
m_mode = ModeWindowClass;
m_class = effects->activeWindow()->windowClass();
}
setActive( !m_activated );
}