diff options
Diffstat (limited to 'src/citra_qt/main.cpp')
-rw-r--r-- | src/citra_qt/main.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/citra_qt/main.cpp b/src/citra_qt/main.cpp index ff2d60996..c5e338c91 100644 --- a/src/citra_qt/main.cpp +++ b/src/citra_qt/main.cpp @@ -167,6 +167,7 @@ GMainWindow::GMainWindow() : emu_thread(nullptr) connect(game_list, SIGNAL(GameChosen(QString)), this, SLOT(OnGameListLoadFile(QString))); connect(ui.action_Load_File, SIGNAL(triggered()), this, SLOT(OnMenuLoadFile())); connect(ui.action_Load_Symbol_Map, SIGNAL(triggered()), this, SLOT(OnMenuLoadSymbolMap())); + connect(ui.action_Select_Game_List_Root, SIGNAL(triggered()), this, SLOT(OnMenuSelectGameListRoot())); connect(ui.action_Start, SIGNAL(triggered()), this, SLOT(OnStartGame())); connect(ui.action_Pause, SIGNAL(triggered()), this, SLOT(OnPauseGame())); connect(ui.action_Stop, SIGNAL(triggered()), this, SLOT(OnStopGame())); @@ -380,6 +381,16 @@ void GMainWindow::OnMenuLoadSymbolMap() { } } +void GMainWindow::OnMenuSelectGameListRoot() { + QSettings settings; + + QString dir_path = QFileDialog::getExistingDirectory(this, tr("Select Directory")); + if (!dir_path.isEmpty()) { + settings.setValue("gameListRootDir", dir_path); + game_list->PopulateAsync(dir_path, settings.value("gameListDeepScan").toBool()); + } +} + void GMainWindow::OnMenuRecentFile() { QAction* action = qobject_cast<QAction*>(sender()); assert(action); |