From 72b50354a0fddd3e4b1c4eb28bf6a3fb92c027bb Mon Sep 17 00:00:00 2001 From: Lucas Murray Date: Mon, 14 Dec 2009 13:30:39 +0000 Subject: [PATCH] Swap if statements around so it makes more sense. Also fix possible logic error. svn path=/trunk/KDE/kdebase/workspace/; revision=1062369 --- client.cpp | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/client.cpp b/client.cpp index b72b580913..390231229b 100644 --- a/client.cpp +++ b/client.cpp @@ -1681,18 +1681,7 @@ void Client::setClientShown( bool shown ) { if( deleting ) return; // Don't change shown status if this client is being deleted - if( !shown && !hidden ) - { - unmap( Allowed ); - hidden = true; - //updateVisibility(); - //updateAllowedActions(); - if( options->inactiveTabsSkipTaskbar ) - setSkipTaskbar( true, false ); // TODO: Causes reshuffle of the taskbar - workspace()->updateFocusChains( this, Workspace::FocusChainMakeLast ); - addWorkspaceRepaint( visibleRect() ); - } - else if( hidden ) + if( shown && hidden ) { map( Allowed ); hidden = false; @@ -1704,6 +1693,17 @@ void Client::setClientShown( bool shown ) autoRaise(); workspace()->updateFocusChains( this, Workspace::FocusChainMakeFirst ); } + if( !shown && !hidden ) + { + unmap( Allowed ); + hidden = true; + //updateVisibility(); + //updateAllowedActions(); + if( options->inactiveTabsSkipTaskbar ) + setSkipTaskbar( true, false ); // TODO: Causes reshuffle of the taskbar + workspace()->updateFocusChains( this, Workspace::FocusChainMakeLast ); + addWorkspaceRepaint( visibleRect() ); + } } void Client::getWMHints()