diff options
| author | 2018-03-19 21:17:15 -0500 | |
|---|---|---|
| committer | 2018-03-19 21:17:15 -0500 | |
| commit | c4ca802b9dc7f0d3f3aed5aa937240bf85370c15 (patch) | |
| tree | 12199ad7acfb7b1b886eda7ad01d968e10c9051c /src/core/hle | |
| parent | Merge pull request #251 from Subv/tic_tsc (diff) | |
| download | yuzu-c4ca802b9dc7f0d3f3aed5aa937240bf85370c15.tar.gz yuzu-c4ca802b9dc7f0d3f3aed5aa937240bf85370c15.tar.xz yuzu-c4ca802b9dc7f0d3f3aed5aa937240bf85370c15.zip | |
FS: Added an SDMC archive factory and registered it to the SDMC archive on startup.
Diffstat (limited to 'src/core/hle')
| -rw-r--r-- | src/core/hle/service/filesystem/filesystem.cpp | 5 | ||||
| -rw-r--r-- | src/core/hle/service/filesystem/filesystem.h | 1 |
2 files changed, 6 insertions, 0 deletions
diff --git a/src/core/hle/service/filesystem/filesystem.cpp b/src/core/hle/service/filesystem/filesystem.cpp index ef05955b9..945832e98 100644 --- a/src/core/hle/service/filesystem/filesystem.cpp +++ b/src/core/hle/service/filesystem/filesystem.cpp | |||
| @@ -6,6 +6,7 @@ | |||
| 6 | #include "common/file_util.h" | 6 | #include "common/file_util.h" |
| 7 | #include "core/file_sys/filesystem.h" | 7 | #include "core/file_sys/filesystem.h" |
| 8 | #include "core/file_sys/savedata_factory.h" | 8 | #include "core/file_sys/savedata_factory.h" |
| 9 | #include "core/file_sys/sdmc_factory.h" | ||
| 9 | #include "core/hle/service/filesystem/filesystem.h" | 10 | #include "core/hle/service/filesystem/filesystem.h" |
| 10 | #include "core/hle/service/filesystem/fsp_srv.h" | 11 | #include "core/hle/service/filesystem/fsp_srv.h" |
| 11 | 12 | ||
| @@ -60,9 +61,13 @@ void RegisterFileSystems() { | |||
| 60 | filesystem_map.clear(); | 61 | filesystem_map.clear(); |
| 61 | 62 | ||
| 62 | std::string nand_directory = FileUtil::GetUserPath(D_NAND_IDX); | 63 | std::string nand_directory = FileUtil::GetUserPath(D_NAND_IDX); |
| 64 | std::string sd_directory = FileUtil::GetUserPath(D_SDMC_IDX); | ||
| 63 | 65 | ||
| 64 | auto savedata = std::make_unique<FileSys::SaveData_Factory>(std::move(nand_directory)); | 66 | auto savedata = std::make_unique<FileSys::SaveData_Factory>(std::move(nand_directory)); |
| 65 | RegisterFileSystem(std::move(savedata), Type::SaveData); | 67 | RegisterFileSystem(std::move(savedata), Type::SaveData); |
| 68 | |||
| 69 | auto sdcard = std::make_unique<FileSys::SDMC_Factory>(std::move(sd_directory)); | ||
| 70 | RegisterFileSystem(std::move(sdcard), Type::SDMC); | ||
| 66 | } | 71 | } |
| 67 | 72 | ||
| 68 | void InstallInterfaces(SM::ServiceManager& service_manager) { | 73 | void InstallInterfaces(SM::ServiceManager& service_manager) { |
diff --git a/src/core/hle/service/filesystem/filesystem.h b/src/core/hle/service/filesystem/filesystem.h index 8d30e94a1..56d26146e 100644 --- a/src/core/hle/service/filesystem/filesystem.h +++ b/src/core/hle/service/filesystem/filesystem.h | |||
| @@ -26,6 +26,7 @@ namespace FileSystem { | |||
| 26 | enum class Type { | 26 | enum class Type { |
| 27 | RomFS = 1, | 27 | RomFS = 1, |
| 28 | SaveData = 2, | 28 | SaveData = 2, |
| 29 | SDMC = 3, | ||
| 29 | }; | 30 | }; |
| 30 | 31 | ||
| 31 | /** | 32 | /** |