GameList: Use ProgressCallback interface when scanning

This commit is contained in:
Connor McLaughlin
2020-03-12 15:32:19 +10:00
parent f71a03202b
commit 9e08ae6188
2 changed files with 35 additions and 6 deletions

View File

@@ -9,6 +9,7 @@
class CDImage;
class ByteStream;
class ProgressCallback;
class SettingsInterface;
@@ -73,7 +74,7 @@ public:
bool IsDatabasePresent() const;
void AddDirectory(std::string path, bool recursive);
void Refresh(bool invalidate_cache, bool invalidate_database);
void Refresh(bool invalidate_cache, bool invalidate_database, ProgressCallback* progress = nullptr);
private:
enum : u32
@@ -97,7 +98,7 @@ private:
bool GetGameListEntry(const std::string& path, GameListEntry* entry);
bool GetGameListEntryFromCache(const std::string& path, GameListEntry* entry);
void ScanDirectory(const char* path, bool recursive);
void ScanDirectory(const char* path, bool recursive, ProgressCallback* progress);
void LoadCache();
bool LoadEntriesFromCache(ByteStream* stream);