summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorColin Harrison <colin.harrison@virgin.net>2012-04-09 15:48:08 +0100
committerJon TURNEY <jon.turney@dronecode.org.uk>2012-11-27 16:26:32 +0000
commita4f357c620ae9e2270316197a61fb8e1d5183a51 (patch)
tree4bb4a19b2e01f78f3e6116ff24833abd892859ad
parenta2983452ee1e2051ab54cded7a3a7735be020db6 (diff)
hw/xwin: Disable minimize button on window with skip-taskbar state
If a window has had its taskbar button removed, disable its minimize button to prevent it becoming lost Signed-off-by: Colin Harrison <colin.harrison@virgin.net> Reviewed-by: Jon TURNEY <jon.turney@dronecode.org.uk>
-rw-r--r--hw/xwin/winmultiwindowwm.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/hw/xwin/winmultiwindowwm.c b/hw/xwin/winmultiwindowwm.c
index 7f7745fec..773fc9767 100644
--- a/hw/xwin/winmultiwindowwm.c
+++ b/hw/xwin/winmultiwindowwm.c
@@ -1731,6 +1731,9 @@ winApplyHints(Display * pDisplay, Window iWindow, HWND hWnd, HWND * zstyle)
if (hint & HINT_NOSYSMENU)
style = style & ~WS_SYSMENU;
+ if (hint & HINT_SKIPTASKBAR)
+ style = style & ~WS_MINIMIZEBOX; /* window will become lost if minimized */
+
SetWindowLongPtr(hWnd, GWL_STYLE, style);
exStyle = GetWindowLongPtr(hWnd, GWL_EXSTYLE);