From a4f357c620ae9e2270316197a61fb8e1d5183a51 Mon Sep 17 00:00:00 2001 From: Colin Harrison Date: Mon, 9 Apr 2012 15:48:08 +0100 Subject: [PATCH] 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 Reviewed-by: Jon TURNEY --- hw/xwin/winmultiwindowwm.c | 3 +++ 1 file changed, 3 insertions(+) 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);