launcher: keep window open when game folder prompt is dismissed (#245)

Calling QApplication::quit() after the user closes the first-run game
folder dialog can segfault during nested modal shutdown. Leave the
launcher open so settings can still be configured. Fixes #121.
This commit is contained in:
Hashim Khan
2026-08-18 07:18:56 +05:00
committed by GitHub
parent 95d282854d
commit 6bf69297c6
+4 -4
View File
@@ -180,10 +180,10 @@ void MainDialogPrivate::FindInterpreter() {
return; return;
} }
if (!m_ui->widget->EnsureGameDirectory()) { // Prompt for a game folder when none are configured, but keep the launcher
QApplication::quit(); // open if the user dismisses the dialog (quitting here can segfault during
return; // nested modal shutdown / background compatibility load).
} m_ui->widget->EnsureGameDirectory();
m_ui->label_settings_file->setText(tr("Settings file: ") + m_ui->widget->GetSettingsFile()); m_ui->label_settings_file->setText(tr("Settings file: ") + m_ui->widget->GetSettingsFile());