impr: Added more generic way to unlock frame rate when needed

This commit is contained in:
WerWolv
2025-07-27 16:25:10 +02:00
parent c7b2f26bd5
commit f42ae97f14
6 changed files with 28 additions and 2 deletions

View File

@@ -283,6 +283,8 @@ namespace hex::plugin::builtin {
if (frontTask == nullptr)
return;
ImHexApi::System::unlockFrameRate();
const auto progress = frontTask->getMaxValue() == 0 ? -1 : float(frontTask->getValue()) / float(frontTask->getMaxValue());
ImHexApi::System::setTaskBarProgress(ImHexApi::System::TaskProgressState::Progress, ImHexApi::System::TaskProgressType::Normal, u32(progress * 100));