diff options
author | Eike Ziller <[email protected]> | 2024-02-21 10:15:28 +0100 |
---|---|---|
committer | Eike Ziller <[email protected]> | 2024-02-21 10:06:41 +0000 |
commit | a130343ab55b9edb4303edabf46b1b87340712f7 (patch) | |
tree | facab6aa9c45dd57e753b1591793e80b0cdac2fc /src | |
parent | 370fb4d550dafd8ededf4b2ecde23d3f48cbcb46 (diff) |
Fix i18n issues
Fix some missing Tr::, and some namespace usages that confused lupdate.
Change-Id: Ib5a411fc53a28a6b807600db50aacc68955ca5dc
Reviewed-by: hjk <[email protected]>
Reviewed-by: Leena Miettinen <[email protected]>
Diffstat (limited to 'src')
-rw-r--r-- | src/libs/utils/macroexpander.cpp | 2 | ||||
-rw-r--r-- | src/plugins/coreplugin/editormanager/editormanager.cpp | 6 | ||||
-rw-r--r-- | src/plugins/coreplugin/find/ifindfilter.cpp | 2 | ||||
-rw-r--r-- | src/plugins/cvs/cvsplugin.cpp | 10 | ||||
-rw-r--r-- | src/plugins/effectcomposer/effectcomposerview.h | 1 | ||||
-rw-r--r-- | src/plugins/languageclient/callhierarchy.cpp | 2 | ||||
-rw-r--r-- | src/plugins/mercurial/mercurialplugin.cpp | 8 | ||||
-rw-r--r-- | src/plugins/projectexplorer/jsonwizard/jsonwizardfactory.cpp | 2 | ||||
-rw-r--r-- | src/plugins/qtapplicationmanager/appmanagerinstallpackagestep.cpp | 4 | ||||
-rw-r--r-- | src/plugins/qtapplicationmanager/appmanagerruncontrol.cpp | 2 | ||||
-rw-r--r-- | src/plugins/remotelinux/linuxdevice.cpp | 4 | ||||
-rw-r--r-- | src/plugins/subversion/subversionplugin.cpp | 6 |
12 files changed, 25 insertions, 24 deletions
diff --git a/src/libs/utils/macroexpander.cpp b/src/libs/utils/macroexpander.cpp index f6d3dad3623..dd57cd6b5a0 100644 --- a/src/libs/utils/macroexpander.cpp +++ b/src/libs/utils/macroexpander.cpp @@ -375,7 +375,7 @@ void MacroExpander::registerIntVariable(const QByteArray &variable, * Convenience function to register several variables with the same \a prefix, that have a file * as a value. Takes the prefix and registers variables like \c{prefix:FilePath} and * \c{prefix:Path}, with descriptions that start with the given \a heading. - * For example \c{registerFileVariables("CurrentDocument", tr("Current Document"))} registers + * For example \c{registerFileVariables("CurrentDocument", Tr::tr("Current Document"))} registers * variables such as \c{CurrentDocument:FilePath} with description * "Current Document: Full path including file name." * diff --git a/src/plugins/coreplugin/editormanager/editormanager.cpp b/src/plugins/coreplugin/editormanager/editormanager.cpp index 10cec9f79ba..6ec37a6cb8c 100644 --- a/src/plugins/coreplugin/editormanager/editormanager.cpp +++ b/src/plugins/coreplugin/editormanager/editormanager.cpp @@ -579,7 +579,7 @@ void EditorManagerPrivate::init() // Go back in navigation history ActionBuilder goBack(this, Constants::GO_BACK); goBack.setIcon(Utils::Icons::PREV.icon()); - goBack.setText(Core::Tr::tr("Go Back")); + goBack.setText(::Core::Tr::tr("Go Back")); goBack.bindContextAction(&m_goBackAction); goBack.setContext(editDesignContext); goBack.setDefaultKeySequence(::Core::Tr::tr("Ctrl+Alt+Left"), ::Core::Tr::tr("Alt+Left")); @@ -589,7 +589,7 @@ void EditorManagerPrivate::init() // Go forward in navigation history ActionBuilder goForward(this, Constants::GO_FORWARD); goForward.setIcon(Utils::Icons::NEXT.icon()); - goForward.setText(Core::Tr::tr("Go Forward")); + goForward.setText(::Core::Tr::tr("Go Forward")); goForward.bindContextAction(&m_goForwardAction); goForward.setContext(editDesignContext); goForward.setDefaultKeySequence(::Core::Tr::tr("Ctrl+Alt+Right"), ::Core::Tr::tr("Alt+Right")); @@ -618,7 +618,7 @@ void EditorManagerPrivate::init() splitSideBySide.setText(::Core::Tr::tr("Split Side by Side")); splitSideBySide.bindContextAction(&m_splitSideBySideAction); splitSideBySide.setContext(editManagerContext); - splitSideBySide.setDefaultKeySequence(::Core::Tr::tr("Meta+E,3"), Core::Tr::tr("Ctrl+E,3")); + splitSideBySide.setDefaultKeySequence(::Core::Tr::tr("Meta+E,3"), ::Core::Tr::tr("Ctrl+E,3")); splitSideBySide.addToContainer(Constants::M_WINDOW, Constants::G_WINDOW_SPLIT); splitSideBySide.addOnTriggered(this, &EditorManager::splitSideBySide); diff --git a/src/plugins/coreplugin/find/ifindfilter.cpp b/src/plugins/coreplugin/find/ifindfilter.cpp index a849598cfdd..704f827bf83 100644 --- a/src/plugins/coreplugin/find/ifindfilter.cpp +++ b/src/plugins/coreplugin/find/ifindfilter.cpp @@ -92,7 +92,7 @@ using namespace Utils; Returns the name of the find filter or scope as presented to the user. This is the name that appears in the scope selection combo box, for example. - Always return a translatable string. That is, use \c tr() for the return + Always return a translatable string. That is, use \c {Tr::tr()} for the return value. */ diff --git a/src/plugins/cvs/cvsplugin.cpp b/src/plugins/cvs/cvsplugin.cpp index 4ca9dd83b39..2688def71e6 100644 --- a/src/plugins/cvs/cvsplugin.cpp +++ b/src/plugins/cvs/cvsplugin.cpp @@ -292,7 +292,7 @@ public: VcsEditorFactory commandLogEditorFactory {{ OtherContent, CVS_COMMANDLOG_EDITOR_ID, - VcsBase::Tr::tr("CVS Command Log Editor"), // display name + ::VcsBase::Tr::tr("CVS Command Log Editor"), // display name "text/vnd.qtcreator.cvs.commandlog", [] { return new CvsEditorWidget; }, std::bind(&CvsPluginPrivate::vcsDescribe, this, _1, _2) @@ -301,7 +301,7 @@ public: VcsEditorFactory logEditorFactory {{ LogOutput, CVS_FILELOG_EDITOR_ID, - VcsBase::Tr::tr("CVS File Log Editor"), // display name + ::VcsBase::Tr::tr("CVS File Log Editor"), // display name "text/vnd.qtcreator.cvs.log", [] { return new CvsEditorWidget; }, std::bind(&CvsPluginPrivate::vcsDescribe, this, _1, _2) @@ -310,7 +310,7 @@ public: VcsEditorFactory annotateEditorFactory {{ AnnotateOutput, CVS_ANNOTATION_EDITOR_ID, - VcsBase::Tr::tr("CVS Annotation Editor"), // display name + ::VcsBase::Tr::tr("CVS Annotation Editor"), // display name "text/vnd.qtcreator.cvs.annotation", [] { return new CvsEditorWidget; }, std::bind(&CvsPluginPrivate::vcsDescribe, this, _1, _2) @@ -319,7 +319,7 @@ public: VcsEditorFactory diffEditorFactory {{ DiffOutput, CVS_DIFF_EDITOR_ID, - VcsBase::Tr::tr("CVS Diff Editor"), // display name + ::VcsBase::Tr::tr("CVS Diff Editor"), // display name "text/x-patch", [] { return new CvsEditorWidget; }, std::bind(&CvsPluginPrivate::vcsDescribe, this, _1, _2) @@ -449,7 +449,7 @@ CvsPluginPrivate::CvsPluginPrivate() setupVcsSubmitEditor(this, { CVS_SUBMIT_MIMETYPE, CVSCOMMITEDITOR_ID, - VcsBase::Tr::tr("CVS Commit Editor"), + ::VcsBase::Tr::tr("CVS Commit Editor"), VcsBaseSubmitEditorParameters::DiffFiles, [] { return new CvsSubmitEditor; }, }); diff --git a/src/plugins/effectcomposer/effectcomposerview.h b/src/plugins/effectcomposer/effectcomposerview.h index a16225dfec4..c7a381cb7db 100644 --- a/src/plugins/effectcomposer/effectcomposerview.h +++ b/src/plugins/effectcomposer/effectcomposerview.h @@ -24,6 +24,7 @@ public: class EffectComposerView : public QmlDesigner::AbstractView { + Q_DECLARE_TR_FUNCTIONS(EffectComposer::EffectComposerView) public: EffectComposerView(QmlDesigner::ExternalDependenciesInterface &externalDependencies); ~EffectComposerView() override; diff --git a/src/plugins/languageclient/callhierarchy.cpp b/src/plugins/languageclient/callhierarchy.cpp index a310fde2a4e..32023e6a98f 100644 --- a/src/plugins/languageclient/callhierarchy.cpp +++ b/src/plugins/languageclient/callhierarchy.cpp @@ -280,7 +280,7 @@ public: Icons::RELOAD_TOOLBAR.icon(); auto button = new QToolButton; button->setIcon(Icons::RELOAD_TOOLBAR.icon()); - button->setToolTip(Tr::tr("Reloads the call hierarchy for the symbol under cursor position.")); + button->setToolTip(::LanguageClient::Tr::tr("Reloads the call hierarchy for the symbol under cursor position.")); connect(button, &QToolButton::clicked, this, [h] { h->updateHierarchyAtCursorPosition(); }); return {h, {button}}; } diff --git a/src/plugins/mercurial/mercurialplugin.cpp b/src/plugins/mercurial/mercurialplugin.cpp index 76c8f2ba8c8..a9ab891c023 100644 --- a/src/plugins/mercurial/mercurialplugin.cpp +++ b/src/plugins/mercurial/mercurialplugin.cpp @@ -146,7 +146,7 @@ public: VcsEditorFactory logEditorFactory {{ LogOutput, Constants::FILELOG_ID, - VcsBase::Tr::tr("Mercurial File Log Editor"), + ::VcsBase::Tr::tr("Mercurial File Log Editor"), Constants::LOGAPP, [] { return new MercurialEditorWidget; }, std::bind(&MercurialPluginPrivate::vcsDescribe, this, _1, _2) @@ -155,7 +155,7 @@ public: VcsEditorFactory annotateEditorFactory {{ AnnotateOutput, Constants::ANNOTATELOG_ID, - VcsBase::Tr::tr("Mercurial Annotation Editor"), + ::VcsBase::Tr::tr("Mercurial Annotation Editor"), Constants::ANNOTATEAPP, [] { return new MercurialEditorWidget; }, std::bind(&MercurialPluginPrivate::vcsDescribe, this, _1, _2) @@ -164,7 +164,7 @@ public: VcsEditorFactory diffEditorFactory {{ DiffOutput, Constants::DIFFLOG_ID, - VcsBase::Tr::tr("Mercurial Diff Editor"), + ::VcsBase::Tr::tr("Mercurial Diff Editor"), Constants::DIFFAPP, [] { return new MercurialEditorWidget; }, std::bind(&MercurialPluginPrivate::vcsDescribe, this, _1, _2) @@ -181,7 +181,7 @@ MercurialPluginPrivate::MercurialPluginPrivate() setupVcsSubmitEditor(this, { Constants::COMMITMIMETYPE, Constants::COMMIT_ID, - VcsBase::Tr::tr("Mercurial Commit Log Editor"), + ::VcsBase::Tr::tr("Mercurial Commit Log Editor"), VcsBaseSubmitEditorParameters::DiffFiles, [] { return new CommitEditor; } }); diff --git a/src/plugins/projectexplorer/jsonwizard/jsonwizardfactory.cpp b/src/plugins/projectexplorer/jsonwizard/jsonwizardfactory.cpp index 0febbcd4149..7f8ff6baf54 100644 --- a/src/plugins/projectexplorer/jsonwizard/jsonwizardfactory.cpp +++ b/src/plugins/projectexplorer/jsonwizard/jsonwizardfactory.cpp @@ -504,7 +504,7 @@ QList<Core::IWizardFactory *> JsonWizardFactory::createWizardFactories() currentFile.parentDir(), &errorMessage); if (!factory) { - verboseLog.append(tr("* Failed to create: %1\n").arg(errorMessage)); + verboseLog.append(Tr::tr("* Failed to create: %1\n").arg(errorMessage)); continue; } diff --git a/src/plugins/qtapplicationmanager/appmanagerinstallpackagestep.cpp b/src/plugins/qtapplicationmanager/appmanagerinstallpackagestep.cpp index 0f995144ec9..f89514ba005 100644 --- a/src/plugins/qtapplicationmanager/appmanagerinstallpackagestep.cpp +++ b/src/plugins/qtapplicationmanager/appmanagerinstallpackagestep.cpp @@ -52,7 +52,7 @@ private: AppManagerInstallPackageStep::AppManagerInstallPackageStep(BuildStepList *bsl, Id id) : AbstractRemoteLinuxDeployStep(bsl, id) { - setDisplayName(tr("Install Application Manager package")); + setDisplayName(Tr::tr("Install Application Manager package")); controller.setDefaultPathValue(getToolFilePath(Constants::APPMAN_CONTROLLER, target()->kit(), @@ -125,7 +125,7 @@ GroupItem AppManagerInstallPackageStep::deployRecipe() }; const auto doneHandler = [this](const Process &process, DoneWith result) { if (result == DoneWith::Success) { - addProgressMessage(tr("Command finished successfully.")); + addProgressMessage(Tr::tr("Command finished successfully.")); } else { if (process.error() != QProcess::UnknownError || process.exitStatus() != QProcess::NormalExit) { diff --git a/src/plugins/qtapplicationmanager/appmanagerruncontrol.cpp b/src/plugins/qtapplicationmanager/appmanagerruncontrol.cpp index ec1aa7244ed..9c485536a44 100644 --- a/src/plugins/qtapplicationmanager/appmanagerruncontrol.cpp +++ b/src/plugins/qtapplicationmanager/appmanagerruncontrol.cpp @@ -232,7 +232,7 @@ private: void start() override { if (m_symbolFile.isEmpty()) { - reportFailure(tr("Cannot debug: Local executable is not set.")); + reportFailure(Tr::tr("Cannot debug: Local executable is not set.")); return; } diff --git a/src/plugins/remotelinux/linuxdevice.cpp b/src/plugins/remotelinux/linuxdevice.cpp index dbad2b5bb18..30fac20a9d9 100644 --- a/src/plugins/remotelinux/linuxdevice.cpp +++ b/src/plugins/remotelinux/linuxdevice.cpp @@ -476,8 +476,8 @@ ProcessResult SshProcessInterface::runInShell(const CommandLine &command, const using namespace std::chrono_literals; process.runBlocking(2s); if (process.result() == ProcessResult::Canceled) { - Core::MessageManager::writeFlashing(tr("Can't send control signal to the %1 device. " - "The device might have been disconnected.") + Core::MessageManager::writeFlashing(Tr::tr("Can't send control signal to the %1 device. " + "The device might have been disconnected.") .arg(d->m_device->displayName())); } return process.result(); diff --git a/src/plugins/subversion/subversionplugin.cpp b/src/plugins/subversion/subversionplugin.cpp index fc9d5ed1222..64f32a11ff2 100644 --- a/src/plugins/subversion/subversionplugin.cpp +++ b/src/plugins/subversion/subversionplugin.cpp @@ -248,7 +248,7 @@ public: VcsEditorFactory logEditorFactory {{ LogOutput, Constants::SUBVERSION_LOG_EDITOR_ID, - VcsBase::Tr::tr("Subversion File Log Editor"), + ::VcsBase::Tr::tr("Subversion File Log Editor"), Constants::SUBVERSION_LOG_MIMETYPE, [] { return new SubversionEditorWidget; }, std::bind(&SubversionPluginPrivate::vcsDescribe, this, _1, _2) @@ -257,7 +257,7 @@ public: VcsEditorFactory blameEditorFactory {{ AnnotateOutput, Constants::SUBVERSION_BLAME_EDITOR_ID, - VcsBase::Tr::tr("Subversion Annotation Editor"), + ::VcsBase::Tr::tr("Subversion Annotation Editor"), Constants::SUBVERSION_BLAME_MIMETYPE, [] { return new SubversionEditorWidget; }, std::bind(&SubversionPluginPrivate::vcsDescribe, this, _1, _2) @@ -468,7 +468,7 @@ SubversionPluginPrivate::SubversionPluginPrivate() setupVcsSubmitEditor(this, { Constants::SUBVERSION_SUBMIT_MIMETYPE, Constants::SUBVERSION_COMMIT_EDITOR_ID, - VcsBase::Tr::tr("Subversion Commit Editor"), + ::VcsBase::Tr::tr("Subversion Commit Editor"), VcsBaseSubmitEditorParameters::DiffFiles, [] { return new SubversionSubmitEditor; }, }); |