diff options
Diffstat (limited to 'Common/NativeApp/src/Win32/WinMain.cpp')
| -rw-r--r-- | Common/NativeApp/src/Win32/WinMain.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/Common/NativeApp/src/Win32/WinMain.cpp b/Common/NativeApp/src/Win32/WinMain.cpp index f82e2c8..b19d8b4 100644 --- a/Common/NativeApp/src/Win32/WinMain.cpp +++ b/Common/NativeApp/src/Win32/WinMain.cpp @@ -59,9 +59,12 @@ int WINAPI WinMain(HINSTANCE instance, HINSTANCE, LPSTR, int cmdShow) 0L, 0L, instance, NULL, NULL, NULL, NULL, WindowClassName, NULL }; RegisterClassEx(&wcex); + int DesiredWidth = 0; + int DesiredHeight = 0; + g_pTheApp->GetDesiredInitialWindowSize(DesiredWidth, DesiredHeight); // Create a window - LONG WindowWidth = 1280; - LONG WindowHeight = 1024; + LONG WindowWidth = DesiredWidth > 0 ? DesiredWidth : 1280; + LONG WindowHeight = DesiredHeight > 0 ? DesiredHeight : 1024; RECT rc = { 0, 0, WindowWidth, WindowHeight }; AdjustWindowRect(&rc, WS_OVERLAPPEDWINDOW, FALSE); HWND wnd = CreateWindowA("SampleApp", AppTitle, |
