mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-11-30 17:53:42 +01:00
Eliminate GetSysDirectories and instead provide a new function: GetSysDirectory.
On Win32, call InitSysDirectories before the emuthread starts just to be safe.
This commit is contained in:
1 parent
533e219862
commit
c7bdeb3084
9 files changed
+77
-57
No files matched your search
+2
-8
@@ -301,12 +301,6 @@ void PathBrowser::Navigate(const std::string &path) {
|
||||
}
|
||||
}
|
||||
|
||||
static std::string GetMemCardDirectory() {
|
||||
std::string memCardDirectory, ignore;
|
||||
GetSysDirectories(memCardDirectory, ignore);
|
||||
return memCardDirectory;
|
||||
}
|
||||
|
||||
class GameBrowser : public UI::LinearLayout {
|
||||
public:
|
||||
GameBrowser(std::string path, bool allowBrowsing, bool *gridStyle_, std::string lastText, std::string lastLink, UI::LayoutParams *layoutParams = 0);
|
||||
@@ -350,7 +344,7 @@ UI::EventReturn GameBrowser::LastClick(UI::EventParams &e) {
|
||||
}
|
||||
|
||||
UI::EventReturn GameBrowser::HomeClick(UI::EventParams &e) {
|
||||
path_.SetPath(GetMemCardDirectory());
|
||||
path_.SetPath(g_Config.memCardDirectory);
|
||||
g_Config.currentDirectory = path_.GetPath();
|
||||
Refresh();
|
||||
return UI::EVENT_DONE;
|
||||
@@ -497,7 +491,7 @@ void MainScreen::CreateViews() {
|
||||
GameBrowser *tabAllGames = new GameBrowser(g_Config.currentDirectory, true, &g_Config.bGridView2,
|
||||
m->T("How to get games"), "http://www.ppsspp.org/getgames.html",
|
||||
new LinearLayoutParams(FILL_PARENT, FILL_PARENT));
|
||||
GameBrowser *tabHomebrew = new GameBrowser(GetMemCardDirectory() + "PSP/GAME/", false, &g_Config.bGridView3,
|
||||
GameBrowser *tabHomebrew = new GameBrowser(GetSysDirectory(DIRECTORY_GAME), false, &g_Config.bGridView3,
|
||||
m->T("How to get homebrew & demos"), "http://www.ppsspp.org/gethomebrew.html",
|
||||
new LinearLayoutParams(FILL_PARENT, FILL_PARENT));
|
||||
|
||||
|
||||
Reference in new issue
Block a user