Assorted directory fixes

This commit is contained in:
Henrik Rydgård committed 2021-07-19 17:34:50 +02:00
1 parent fff3850096
commit b0558b2174
7 files changed
+25 -6

No files matched your search

+10
View File
@@ -541,10 +541,20 @@ UI::EventReturn GameBrowser::StorageClick(UI::EventParams &e) {
}
UI::EventReturn GameBrowser::HomeClick(UI::EventParams &e) {
if (System_GetPropertyBool(SYSPROP_ANDROID_SCOPED_STORAGE)) {
if (path_.GetPath().Type() == PathType::CONTENT_URI) {
path_.SetPath(path_.GetPath().GetRootVolume());
return UI::EVENT_DONE;
}
}
SetPath(HomePath());
return UI::EVENT_DONE;
}
// TODO: This doesn't make that much sense for Android, especially after scoped storage..
// Maybe we should have no home directory in this case. Or it should just navigate to the root
// of the current folder tree.
Path GameBrowser::HomePath() {
#if PPSSPP_PLATFORM(ANDROID) || PPSSPP_PLATFORM(SWITCH) || defined(USING_WIN_UI) || PPSSPP_PLATFORM(UWP)
return g_Config.memStickDirectory;