Don't crash when focus chain is empty.
svn path=/trunk/KDE/kdebase/workspace/; revision=1022903
This commit is contained in:
parent
c4b279eed5
commit
eee788f45a
1 changed files with 7 additions and 2 deletions
|
@ -91,8 +91,13 @@ QString TabBoxHandlerImpl::desktopName( int desktop ) const
|
|||
|
||||
TabBoxClient* TabBoxHandlerImpl::nextClientFocusChain( TabBoxClient* client ) const
|
||||
{
|
||||
Client* current = (static_cast< TabBoxClientImpl* >( client ))->client();
|
||||
return Workspace::self()->nextClientFocusChain( current )->tabBoxClient();
|
||||
if( TabBoxClientImpl* c = static_cast< TabBoxClientImpl* >( client ) )
|
||||
{
|
||||
Client* next = Workspace::self()->nextClientFocusChain( c->client() );
|
||||
if( next )
|
||||
return next->tabBoxClient();
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
int TabBoxHandlerImpl::nextDesktopFocusChain( int desktop ) const
|
||||
|
|
Loading…
Reference in a new issue