Don't try to draw icon for windows that don't have one

svn path=/trunk/KDE/kdebase/workspace/; revision=688598
icc-effect-5.14.5
Rivo Laks 2007-07-16 11:50:01 +00:00
parent faf536a3b8
commit 1ec2b1d228
1 changed files with 6 additions and 0 deletions

View File

@ -545,6 +545,12 @@ void BoxSwitchEffect::paintWindowIcon( EffectWindow* w )
{
if( !windows.contains( w ))
return;
// Don't render null icons
if( w->icon().isNull() )
{
return;
}
if( windows[ w ]->icon.serialNumber() != w->icon().serialNumber())
{ // make sure windows[ w ]->icon is the right QPixmap, and rebind
windows[ w ]->icon = w->icon();