summaryrefslogtreecommitdiff
path: root/src/core/loader/nro.h
diff options
context:
space:
mode:
authorGravatar Zach Hilman2018-07-18 21:07:11 -0400
committerGravatar bunnei2018-07-18 18:07:11 -0700
commit29aff8d5ab46c8d0199aa4bfa7eeff5d4fa2d7ef (patch)
tree3202e2ce55ab6387a4ca366a509eccdd963434c3 /src/core/loader/nro.h
parentMerge pull request #683 from DarkLordZach/touch (diff)
downloadyuzu-29aff8d5ab46c8d0199aa4bfa7eeff5d4fa2d7ef.tar.gz
yuzu-29aff8d5ab46c8d0199aa4bfa7eeff5d4fa2d7ef.tar.xz
yuzu-29aff8d5ab46c8d0199aa4bfa7eeff5d4fa2d7ef.zip
Virtual Filesystem 2: Electric Boogaloo (#676)
* Virtual Filesystem * Fix delete bug and documentate * Review fixes + other stuff * Fix puyo regression
Diffstat (limited to 'src/core/loader/nro.h')
-rw-r--r--src/core/loader/nro.h13
1 files changed, 5 insertions, 8 deletions
diff --git a/src/core/loader/nro.h b/src/core/loader/nro.h
index 599adb253..2c03d06bb 100644
--- a/src/core/loader/nro.h
+++ b/src/core/loader/nro.h
@@ -15,26 +15,23 @@ namespace Loader {
15/// Loads an NRO file 15/// Loads an NRO file
16class AppLoader_NRO final : public AppLoader, Linker { 16class AppLoader_NRO final : public AppLoader, Linker {
17public: 17public:
18 AppLoader_NRO(FileUtil::IOFile&& file, std::string filepath); 18 AppLoader_NRO(FileSys::VirtualFile file);
19 19
20 /** 20 /**
21 * Returns the type of the file 21 * Returns the type of the file
22 * @param file FileUtil::IOFile open file 22 * @param file std::shared_ptr<VfsFile> open file
23 * @param filepath Path of the file that we are opening.
24 * @return FileType found, or FileType::Error if this loader doesn't know it 23 * @return FileType found, or FileType::Error if this loader doesn't know it
25 */ 24 */
26 static FileType IdentifyType(FileUtil::IOFile& file, const std::string& filepath); 25 static FileType IdentifyType(const FileSys::VirtualFile& file);
27 26
28 FileType GetFileType() override { 27 FileType GetFileType() override {
29 return IdentifyType(file, filepath); 28 return IdentifyType(file);
30 } 29 }
31 30
32 ResultStatus Load(Kernel::SharedPtr<Kernel::Process>& process) override; 31 ResultStatus Load(Kernel::SharedPtr<Kernel::Process>& process) override;
33 32
34private: 33private:
35 bool LoadNro(const std::string& path, VAddr load_base); 34 bool LoadNro(FileSys::VirtualFile file, VAddr load_base);
36
37 std::string filepath;
38}; 35};
39 36
40} // namespace Loader 37} // namespace Loader