Merge pull request #2148 from Cacodemon345/patch-61

qt: Fix high CPU usage when paused
This commit is contained in:
Miran Grča
2022-02-20 12:26:42 +01:00
committed by GitHub

View File

@@ -114,7 +114,7 @@ main_thread_fn()
}
} else {
/* Just so we dont overload the host OS. */
if (drawits < -1)
if (drawits < -1 || dopause)
std::this_thread::sleep_for(std::chrono::milliseconds(1));
else
std::this_thread::yield();