aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorpineappleEA <pineaea@gmail.com>2021-10-12 05:11:52 +0200
committerpineappleEA <pineaea@gmail.com>2021-10-12 05:11:52 +0200
commit7e08e56bac7406247bf231bd4662f4370d7b52d8 (patch)
treeaea0ba8e43903cc0ac5950c146efedb4bbe98c62
parent1638b63a4c06a85f5d777bc82e0eb8c17b1afcd3 (diff)
early-access version 2123EA-2123
-rwxr-xr-xREADME.md2
-rwxr-xr-xsrc/common/fs/path_util.cpp27
2 files changed, 16 insertions, 13 deletions
diff --git a/README.md b/README.md
index 8a0980eca..a911fb191 100755
--- a/README.md
+++ b/README.md
@@ -1,7 +1,7 @@
1yuzu emulator early access 1yuzu emulator early access
2============= 2=============
3 3
4This is the source code for early-access 2122. 4This is the source code for early-access 2123.
5 5
6## Legal Notice 6## Legal Notice
7 7
diff --git a/src/common/fs/path_util.cpp b/src/common/fs/path_util.cpp
index 43b79bd6d..1bcb897b5 100755
--- a/src/common/fs/path_util.cpp
+++ b/src/common/fs/path_util.cpp
@@ -82,32 +82,35 @@ public:
82 82
83private: 83private:
84 PathManagerImpl() { 84 PathManagerImpl() {
85 fs::path yuzu_path;
86 fs::path yuzu_path_cache;
87 fs::path yuzu_path_config;
88
85#ifdef _WIN32 89#ifdef _WIN32
86 auto yuzu_path = GetExeDirectory() / PORTABLE_DIR; 90 yuzu_path = GetExeDirectory() / PORTABLE_DIR;
87 91
88 if (!IsDir(yuzu_path)) { 92 if (!IsDir(yuzu_path)) {
89 yuzu_path = GetAppDataRoamingDirectory() / YUZU_DIR; 93 yuzu_path = GetAppDataRoamingDirectory() / YUZU_DIR;
90 } 94 }
91 95
92 GenerateYuzuPath(YuzuPath::YuzuDir, yuzu_path); 96 yuzu_path_cache = yuzu_path / CACHE_DIR;
93 GenerateYuzuPath(YuzuPath::CacheDir, yuzu_path / CACHE_DIR); 97 yuzu_path_config = yuzu_path / CONFIG_DIR;
94 GenerateYuzuPath(YuzuPath::ConfigDir, yuzu_path / CONFIG_DIR);
95#else 98#else
96 auto yuzu_path = GetCurrentDir() / PORTABLE_DIR; 99 yuzu_path = GetCurrentDir() / PORTABLE_DIR;
97 100
98 if (Exists(yuzu_path) && IsDir(yuzu_path)) { 101 if (Exists(yuzu_path) && IsDir(yuzu_path)) {
99 GenerateYuzuPath(YuzuPath::YuzuDir, yuzu_path); 102 yuzu_path_cache = yuzu_path / CACHE_DIR;
100 GenerateYuzuPath(YuzuPath::CacheDir, yuzu_path / CACHE_DIR); 103 yuzu_path_config = yuzu_path / CONFIG_DIR;
101 GenerateYuzuPath(YuzuPath::ConfigDir, yuzu_path / CONFIG_DIR);
102 } else { 104 } else {
103 yuzu_path = GetDataDirectory("XDG_DATA_HOME") / YUZU_DIR; 105 yuzu_path = GetDataDirectory("XDG_DATA_HOME") / YUZU_DIR;
104 106 yuzu_path_cache = GetDataDirectory("XDG_CACHE_HOME") / YUZU_DIR;
105 GenerateYuzuPath(YuzuPath::YuzuDir, yuzu_path); 107 yuzu_path_config = GetDataDirectory("XDG_CONFIG_HOME") / YUZU_DIR;
106 GenerateYuzuPath(YuzuPath::CacheDir, GetDataDirectory("XDG_CACHE_HOME") / YUZU_DIR);
107 GenerateYuzuPath(YuzuPath::ConfigDir, GetDataDirectory("XDG_CONFIG_HOME") / YUZU_DIR);
108 } 108 }
109#endif 109#endif
110 110
111 GenerateYuzuPath(YuzuPath::YuzuDir, yuzu_path);
112 GenerateYuzuPath(YuzuPath::CacheDir, yuzu_path_cache);
113 GenerateYuzuPath(YuzuPath::ConfigDir, yuzu_path_config);
111 GenerateYuzuPath(YuzuPath::DumpDir, yuzu_path / DUMP_DIR); 114 GenerateYuzuPath(YuzuPath::DumpDir, yuzu_path / DUMP_DIR);
112 GenerateYuzuPath(YuzuPath::KeysDir, yuzu_path / KEYS_DIR); 115 GenerateYuzuPath(YuzuPath::KeysDir, yuzu_path / KEYS_DIR);
113 GenerateYuzuPath(YuzuPath::LoadDir, yuzu_path / LOAD_DIR); 116 GenerateYuzuPath(YuzuPath::LoadDir, yuzu_path / LOAD_DIR);