Add metafilesystem hook to add optimized implementations of compute recursive directory size

This commit is contained in:
Henrik Rydgård committed 2021-09-11 18:12:29 +02:00
1 parent e842d395fa
commit 48310d15a9
11 files changed
+88 -13

No files matched your search

+5
View File
@@ -115,6 +115,9 @@ public:
FileSystemFlags Flags() override { return flags; }
u64 FreeSpace(const std::string &path) override;
// TODO: Replace with optimized implementation.
bool ComputeRecursiveDirSizeIfFast(const std::string &path, int64_t *size) override { return false; }
private:
struct OpenFileEntry {
DirectoryFileHandle hFile;
@@ -159,6 +162,8 @@ public:
FileSystemFlags Flags() override { return FileSystemFlags::FLASH; }
u64 FreeSpace(const std::string &path) override { return 0; }
bool ComputeRecursiveDirSizeIfFast(const std::string &path, int64_t *size) override { return false; }
private:
struct OpenFileEntry {
u8 *fileData;