1
0
mirror of https://github.com/FunkyFr3sh/cnc-ddraw.git synced 2025-03-15 06:04:49 +01:00

Do not save settings while window is maxmized in macOS

This commit is contained in:
FunkyFr3sh 2024-10-03 04:27:04 +02:00
parent 116297d2b4
commit 07e088faaa
2 changed files with 4 additions and 2 deletions

View File

@ -131,6 +131,10 @@ void cfg_save()
if (!g_config.save_settings)
return;
/* Do not save settings while window is maxmized */
if (IsMacOS() && !g_config.window_rect.left && !g_config.window_rect.top)
return;
char buf[16];
char* section = g_config.save_settings == 1 ? "ddraw" : g_config.process_file_name;

View File

@ -453,8 +453,6 @@ LRESULT CALLBACK fake_WndProc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam
WaitForSingleObject(g_ddraw.render.thread, INFINITE);
g_ddraw.render.thread = NULL;
g_config.save_settings = 0;
}
if (in_size_move && !g_ddraw.render.thread)