mirror of
https://github.com/WerWolv/ImHex.git
synced 2026-03-30 05:05:19 -05:00
impr: Added more generic way to unlock frame rate when needed
This commit is contained in:
@@ -355,8 +355,10 @@ namespace hex {
|
||||
if (ImGui::GetPlatformIO().Viewports.size() > 1)
|
||||
unlockFrameRate();
|
||||
|
||||
// Unlock frame rate if there's any task running that shows a loading animation
|
||||
if (TaskManager::getRunningTaskCount() > 0 || TaskManager::getRunningBlockingTaskCount() > 0) {
|
||||
// Unlock frame rate if the frame rate was requested to be unlocked
|
||||
if (ImHexApi::System::impl::frameRateUnlockRequested()) {
|
||||
ImHexApi::System::impl::resetFrameRateUnlockRequested();
|
||||
|
||||
glfwPostEmptyEvent();
|
||||
unlockFrameRate();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user