Don't crash when you happen to select a window with alt-tab that has just

disappeared. (forward port)

svn path=/trunk/kdebase/kwin/; revision=121076
icc-effect-5.14.5
Waldo Bastian 2001-11-07 01:09:29 +00:00
parent c773447e44
commit a29eb333d0
2 changed files with 7 additions and 0 deletions

View File

@ -161,6 +161,8 @@ Client* TabBox::currentClient()
{
if ( mode() != WindowsMode )
return 0;
if (!workspace()->hasClient( client ))
return 0;
return client;
}

View File

@ -736,6 +736,7 @@ bool Workspace::destroyClient( Client* c)
return FALSE;
storeFakeSessionInfo( c );
if (clients.contains(c))
removeClient(c);
@ -752,6 +753,10 @@ bool Workspace::destroyClient( Client* c)
if ( c == last_active_client )
last_active_client = 0;
delete c;
if (tab_grab)
tab_box->repaint();
updateClientArea();
return TRUE;
}