mirror of
https://github.com/doitsujin/dxvk.git
synced 2025-02-27 04:54:15 +01:00
[d3d9] Don't adjust window position and size in windowed mode.
This commit is contained in:
parent
cde0fbe7b0
commit
cc11bb8240
@ -631,21 +631,6 @@ namespace dxvk {
|
|||||||
if (pPresentParams->Windowed) {
|
if (pPresentParams->Windowed) {
|
||||||
if (changeFullscreen)
|
if (changeFullscreen)
|
||||||
this->LeaveFullscreenMode();
|
this->LeaveFullscreenMode();
|
||||||
|
|
||||||
// Adjust window position and size
|
|
||||||
RECT newRect = { 0, 0, 0, 0 };
|
|
||||||
RECT oldRect = { 0, 0, 0, 0 };
|
|
||||||
|
|
||||||
::GetWindowRect(m_window, &oldRect);
|
|
||||||
::MapWindowPoints(HWND_DESKTOP, ::GetParent(m_window), reinterpret_cast<POINT*>(&oldRect), 1);
|
|
||||||
::SetRect(&newRect, 0, 0, pPresentParams->BackBufferWidth, pPresentParams->BackBufferHeight);
|
|
||||||
::AdjustWindowRectEx(&newRect,
|
|
||||||
::GetWindowLongW(m_window, GWL_STYLE), FALSE,
|
|
||||||
::GetWindowLongW(m_window, GWL_EXSTYLE));
|
|
||||||
::SetRect(&newRect, 0, 0, newRect.right - newRect.left, newRect.bottom - newRect.top);
|
|
||||||
::OffsetRect(&newRect, oldRect.left, oldRect.top);
|
|
||||||
::MoveWindow(m_window, newRect.left, newRect.top,
|
|
||||||
newRect.right - newRect.left, newRect.bottom - newRect.top, TRUE);
|
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
if (changeFullscreen) {
|
if (changeFullscreen) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user