mirror of
https://github.com/glfw/glfw.git
synced 2026-09-22 00:49:48 +00:00
Cleanup
Put the non-client painting related message cases with the client ones so that they can be happy together. Related to #1383.
This commit is contained in:
+11
-13
@@ -1060,6 +1060,17 @@ static LRESULT CALLBACK windowProc(HWND hWnd, UINT uMsg,
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
case WM_NCACTIVATE:
|
||||
case WM_NCPAINT:
|
||||
{
|
||||
// Prevent title bar from being drawn after restoring a minimized
|
||||
// undecorated window
|
||||
if (!window->decorated)
|
||||
return TRUE;
|
||||
|
||||
break;
|
||||
}
|
||||
|
||||
case WM_DWMCOMPOSITIONCHANGED:
|
||||
{
|
||||
if (window->win32.transparent)
|
||||
@@ -1161,19 +1172,6 @@ static LRESULT CALLBACK windowProc(HWND hWnd, UINT uMsg,
|
||||
DragFinish(drop);
|
||||
return 0;
|
||||
}
|
||||
|
||||
case WM_NCACTIVATE:
|
||||
case WM_NCPAINT:
|
||||
{
|
||||
// HACK: Prevent title bar artifacts from appearing after restoring
|
||||
// a minimized borderless window
|
||||
if (!window->decorated)
|
||||
{
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
return DefWindowProcW(hWnd, uMsg, wParam, lParam);
|
||||
|
||||
Reference in New Issue
Block a user