GameList: Fix progress disappearing when scanning >1 directory

This commit is contained in:
Connor McLaughlin 2020-10-12 00:40:06 +10:00
parent ad61815cad
commit a372a1d782

View file

@ -696,10 +696,11 @@ void GameList::Refresh(bool invalidate_cache, bool invalidate_database, Progress
progress->SetProgressRange(static_cast<u32>(m_search_directories.size()));
progress->SetProgressValue(0);
for (DirectoryEntry& de : m_search_directories)
for (u32 i = 0; i < static_cast<u32>(m_search_directories.size()); i++)
{
const DirectoryEntry& de = m_search_directories[i];
ScanDirectory(de.path.c_str(), de.recursive, progress);
progress->IncrementProgressValue();
progress->SetProgressValue(i + 1);
}
}