From aecd79a57c82612dc76a48993ae28b0fa1bcb4ab Mon Sep 17 00:00:00 2001 From: fallenoak Date: Wed, 15 Mar 2023 16:10:25 -0500 Subject: [PATCH] feat(gx): adjust window for desired client area in d3d backend --- src/gx/d3d/CGxDeviceD3d.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/gx/d3d/CGxDeviceD3d.cpp b/src/gx/d3d/CGxDeviceD3d.cpp index 13ac5f5..f2b001b 100644 --- a/src/gx/d3d/CGxDeviceD3d.cpp +++ b/src/gx/d3d/CGxDeviceD3d.cpp @@ -917,6 +917,16 @@ bool CGxDeviceD3d::ICreateWindow(CGxFormat& format) { // TODO + RECT clientArea = { + 0, // left + 0, // top + format.size.x, // right + format.size.y // bottom + }; + AdjustWindowRectEx(&clientArea, dwStyle, false, 0); + + // TODO + int32_t width = format.size.x ? format.size.x : CW_USEDEFAULT; int32_t height = format.size.y ? format.size.y : CW_USEDEFAULT;