1
0
mirror of https://github.com/RPCS3/rpcs3.git synced 2024-11-22 18:53:28 +01:00

Fix ppu progress dialog percentage

This commit is contained in:
Eladash 2021-01-31 07:30:42 +02:00 committed by Megamouse
parent b3fbada10e
commit 8d15f44b33

View File

@ -385,9 +385,10 @@ namespace
pdone = pdone_new;
// Compute new progress in percents
const u32 total = ftotal + ptotal;
const u32 done = fdone + pdone;
const double value = double(done) * 100. / double(total ? total : 1);
// Assume not all programs were found if files were not compiled (as it may contain more)
const u64 total = std::max<u64>(ptotal, 1) * std::max<u64>(ftotal, 1);
const u64 done = pdone * std::max<u64>(fdone, 1);
const double value = std::fmin(done * 100. / total, 100.);
// Changes detected, send update
Emu.CallAfter([=]()