summaryrefslogtreecommitdiffstats
path: root/twin
diff options
context:
space:
mode:
authorSlávek Banko <slavek.banko@axis.cz>2012-12-22 12:31:37 +0100
committerSlávek Banko <slavek.banko@axis.cz>2012-12-22 12:31:37 +0100
commit55c907ad0e031f2ceddb2693761b747395137ac0 (patch)
treed7fa44bd404cf6aacbe9f78d632fff977a88b107 /twin
parentdd89b1bd550eb954e4b9e075ff15b45855f407ed (diff)
downloadtdebase-55c907ad0e031f2ceddb2693761b747395137ac0.tar.gz
tdebase-55c907ad0e031f2ceddb2693761b747395137ac0.zip
Unset/set NETWM shading state around minimizing
Based on KDE GIT commit 8a02a383
Diffstat (limited to 'twin')
-rw-r--r--twin/client.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/twin/client.cpp b/twin/client.cpp
index 35b588db5..f421560a4 100644
--- a/twin/client.cpp
+++ b/twin/client.cpp
@@ -664,6 +664,9 @@ void Client::minimize( bool avoid_animation )
if ( !isMinimizable() || isMinimized())
return;
+ if (isShade()) // NETWM restriction - KWindowInfo::isMinimized() == Hidden && !Shaded
+ info->setState(0, NET::Shaded);
+
Notify::raise( Notify::Minimize );
// SELI mainClients().isEmpty() ??? - and in unminimize() too
@@ -687,6 +690,9 @@ void Client::unminimize( bool avoid_animation )
if( !isMinimized())
return;
+ if (isShade()) // NETWM restriction - KWindowInfo::isMinimized() == Hidden && !Shaded
+ info->setState(NET::Shaded, NET::Shaded);
+
Notify::raise( Notify::UnMinimize );
minimized = false;
if( isOnCurrentDesktop() && isShown( true ))
@@ -947,7 +953,7 @@ void Client::setShade( ShadeMode mode )
workspace()->requestFocus( this );
}
checkMaximizeGeometry();
- info->setState( isShade() ? NET::Shaded : 0, NET::Shaded );
+ info->setState( (isShade() && !isMinimized()) ? NET::Shaded : 0, NET::Shaded );
info->setState( isShown( false ) ? 0 : NET::Hidden, NET::Hidden );
updateVisibility();
updateAllowedActions();