mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-28 11:49:06 +00:00
DolphinQt: Implement "Purge Game List Cache"
This is a missing feature from DolphinWX.
This commit is contained in:
parent
8d1e996f39
commit
8bbec31295
11 changed files with 41 additions and 3 deletions
|
@ -24,13 +24,19 @@ std::vector<std::string> FindAllGamePaths(const std::vector<std::string>& direct
|
|||
class GameFileCache
|
||||
{
|
||||
public:
|
||||
enum class DeleteOnDisk
|
||||
{
|
||||
No = 0,
|
||||
Yes = 1,
|
||||
};
|
||||
|
||||
GameFileCache(); // Uses the default path
|
||||
explicit GameFileCache(std::string path);
|
||||
|
||||
void ForEach(std::function<void(const std::shared_ptr<const GameFile>&)> f) const;
|
||||
|
||||
size_t GetSize() const;
|
||||
void Clear();
|
||||
void Clear(DeleteOnDisk delete_on_disk);
|
||||
|
||||
// Returns nullptr if the file is invalid.
|
||||
std::shared_ptr<const GameFile> AddOrGet(const std::string& path, bool* cache_changed);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue