diff options
| author | Jeremy Rimpo <jeremy.rimpo@servermonkey.com> | 2023-10-05 09:17:40 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-10-05 09:17:40 -0500 |
| commit | 48e8fdff0df30fa807e61d4df7b6116a9d190f2f (patch) | |
| tree | 287138c11f967ef3fd37aa9935fefcebf492163b /src/mainwindow.cpp | |
| parent | e9a5e5b274bed8c407ecbf0b10155ac8fae8f60b (diff) | |
| parent | 09b8baac5a3bdf0707c9f4c08692b95f93d2dc2b (diff) | |
Merge pull request #1897 from ModOrganizer2/tutorial_translation_fixes
Tutorial translation updates
Diffstat (limited to 'src/mainwindow.cpp')
| -rw-r--r-- | src/mainwindow.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index eb52350f..eb78eb96 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -1075,6 +1075,12 @@ void MainWindow::createEndorseMenu() void MainWindow::createHelpMenu() { + //: Translation strings for tutorial names + static std::map<QString, const char*> translate = { + {"First Steps", QT_TR_NOOP("First Steps")}, + {"Conflict Resolution", QT_TR_NOOP("Conflict Resolution")}, + {"Overview", QT_TR_NOOP("Overview")}}; + auto* menu = ui->actionHelp->menu(); if (!menu) { // this happens on startup because languageChanged() (which calls this) is @@ -1131,7 +1137,7 @@ void MainWindow::createHelpMenu() fileName); continue; } - QAction* tutAction = new QAction(params.at(0), tutorialMenu); + QAction* tutAction = new QAction(tr(translate[params.at(0)]), tutorialMenu); tutAction->setData(fileName); tutorials.push_back(std::make_pair(params.at(1).toInt(), tutAction)); } |
