From 3be33a0a23b8732e57bd82403e4213a258634cff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Bernon?= Date: Fri, 26 Feb 2021 19:10:38 +0100 Subject: [PATCH] [d3d9] Convert window position relative to its parent. --- src/d3d9/d3d9_swapchain.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/d3d9/d3d9_swapchain.cpp b/src/d3d9/d3d9_swapchain.cpp index cda6fc781b9..168dbf0b6a4 100644 --- a/src/d3d9/d3d9_swapchain.cpp +++ b/src/d3d9/d3d9_swapchain.cpp @@ -617,6 +617,7 @@ namespace dxvk { RECT oldRect = { 0, 0, 0, 0 }; ::GetWindowRect(m_window, &oldRect); + ::MapWindowPoints(HWND_DESKTOP, ::GetParent(m_window), reinterpret_cast(&oldRect), 1); ::SetRect(&newRect, 0, 0, pPresentParams->BackBufferWidth, pPresentParams->BackBufferHeight); ::AdjustWindowRectEx(&newRect, ::GetWindowLongW(m_window, GWL_STYLE), FALSE,