GameList: Scan hidden files

This commit is contained in:
Connor McLaughlin 2021-07-21 20:25:52 +10:00
parent 3847c94a42
commit 3cc7802897
1 changed files with 4 additions and 1 deletions

View File

@ -471,7 +471,10 @@ void GameList::ScanDirectory(const char* path, bool recursive, ProgressCallback*
progress->SetFormattedStatusText("Scanning directory '%s'%s...", path, recursive ? " (recursively)" : ""); progress->SetFormattedStatusText("Scanning directory '%s'%s...", path, recursive ? " (recursively)" : "");
FileSystem::FindResultsArray files; FileSystem::FindResultsArray files;
FileSystem::FindFiles(path, "*", FILESYSTEM_FIND_FILES | (recursive ? FILESYSTEM_FIND_RECURSIVE : 0), &files); FileSystem::FindFiles(path, "*",
recursive ? (FILESYSTEM_FIND_FILES | FILESYSTEM_FIND_HIDDEN_FILES | FILESYSTEM_FIND_RECURSIVE) :
(FILESYSTEM_FIND_FILES | FILESYSTEM_FIND_HIDDEN_FILES),
&files);
progress->SetProgressRange(static_cast<u32>(files.size())); progress->SetProgressRange(static_cast<u32>(files.size()));
progress->SetProgressValue(0); progress->SetProgressValue(0);