From f0f16a3a691f609608d26624eaa0addf55b78c8a Mon Sep 17 00:00:00 2001 From: andreja6 Date: Sun, 29 Apr 2018 20:00:00 -0700 Subject: [PATCH] Tried changing how window starts --- main.cpp | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/main.cpp b/main.cpp index 2259083..0bd2be5 100644 --- a/main.cpp +++ b/main.cpp @@ -1700,12 +1700,14 @@ int main(int argc, char** argv) { SetWindowPos(hwndMain, NULL, 0, 0, 800, 600, NULL); - HMONITOR monitor = MonitorFromWindow(hwndMain, MONITOR_DEFAULTTONEAREST); - MONITORINFO lpmi; - GetMonitorInfo( monitor, &lpmi); - int widthMON = lpmi.rcMonitor.bottom; - int heightMON = lpmi.rcMonitor.right; + + if(GetClientRect(hwndMain, &rect)) + { + width = rect.right - rect.left; + height = rect.bottom - rect.top; + } + SetWindowPos(hwnd, NULL, 0, 0, width, height, NULL); //message = Convert(widthMON) + ", " + Convert(heightMON); //messageTime = G3D::System::time();