Qt: Enable switching of languages without restarting app

This commit is contained in:
Connor McLaughlin
2021-08-16 14:06:54 +10:00
parent 47f85dc453
commit 35bb20e586
3 changed files with 18 additions and 3 deletions

View File

@ -970,8 +970,8 @@ void MainWindow::setupAdditionalUi()
connect(action, &QAction::triggered, [this, action]() {
const QString new_language = action->data().toString();
m_host_interface->SetStringSettingValue("Main", "Language", new_language.toUtf8().constData());
QMessageBox::information(this, tr("DuckStation"),
tr("Language changed. Please restart the application to apply."));
m_host_interface->reinstallTranslator();
recreate();
});
}