From 3c4ec82617bb577883604e6a333cebfd67c182d4 Mon Sep 17 00:00:00 2001 From: FunkyFr3sh Date: Thu, 24 Aug 2023 19:18:12 +0200 Subject: [PATCH] make sure window titlebar is visible if window bigger than screen --- src/dd.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/dd.c b/src/dd.c index 99c9801..c729a1d 100644 --- a/src/dd.c +++ b/src/dd.c @@ -887,6 +887,11 @@ HRESULT dd_SetDisplayMode(DWORD dwWidth, DWORD dwHeight, DWORD dwBPP, DWORD dwFl { x = y = 0; } + else if (border && g_config.window_rect.top == -32000 && y < 0) + { + /* Make window titlebar visible if window does not fit into screen */ + y = real_GetSystemMetrics(SM_CYCAPTION) + real_GetSystemMetrics(SM_CYSIZEFRAME); + } if (util_is_minimized(g_ddraw->hwnd)) real_ShowWindow(g_ddraw->hwnd, SW_RESTORE);