Merge pull request #12787 from sonninnos/win32-orig-refresh

(WIN32) Remember original refresh rate
This commit is contained in:
Autechre 2021-08-12 19:24:01 +02:00 committed by GitHub
commit 9e84c5c2c8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -238,7 +238,8 @@ static bool win32_display_server_set_resolution(void *data,
serv->orig_width = GetSystemMetrics(SM_CXSCREEN);
if (serv->orig_height == 0)
serv->orig_height = GetSystemMetrics(SM_CYSCREEN);
serv->orig_refresh = dm.dmDisplayFrequency;
if (serv->orig_refresh == 0)
serv->orig_refresh = dm.dmDisplayFrequency;
/* Used to stop super resolution bug */
if (width == dm.dmPelsWidth)