Translations: Call Tr::tr() where it should

Change-Id: Ibf2be8a9aabd0a4e8e763a96901feaaa6eda2f3e
Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
Alessandro Portale
2023-06-09 13:33:02 +02:00
parent 005a26d0ae
commit 50c386b53a
4 changed files with 7 additions and 4 deletions

View File

@@ -455,7 +455,7 @@ void TestRunner::runTestsHelper()
connect(m_taskTree.get(), &TaskTree::errorOccurred, this, &TestRunner::onFinished); connect(m_taskTree.get(), &TaskTree::errorOccurred, this, &TestRunner::onFinished);
auto progress = new TaskProgress(m_taskTree.get()); auto progress = new TaskProgress(m_taskTree.get());
progress->setDisplayName(tr("Running Tests")); progress->setDisplayName(Tr::tr("Running Tests"));
progress->setAutoStopOnCancel(false); progress->setAutoStopOnCancel(false);
progress->setHalfLifeTimePerTask(10000); // 10 seconds progress->setHalfLifeTimePerTask(10000); // 10 seconds
connect(progress, &TaskProgress::canceled, this, [this, progress] { connect(progress, &TaskProgress::canceled, this, [this, progress] {

View File

@@ -2,7 +2,9 @@
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0+ OR GPL-3.0 WITH Qt-GPL-exception-1.0 // SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0+ OR GPL-3.0 WITH Qt-GPL-exception-1.0
#include "qmlbuildsystem.h" #include "qmlbuildsystem.h"
#include "../qmlprojectconstants.h" #include "../qmlprojectconstants.h"
#include "../qmlprojectmanagertr.h"
#include <QtCore5Compat/qtextcodec.h> #include <QtCore5Compat/qtextcodec.h>
#include <qmljs/qmljsmodelmanagerinterface.h> #include <qmljs/qmljsmodelmanagerinterface.h>
@@ -222,7 +224,7 @@ void QmlBuildSystem::parseProjectFiles()
QString errorMessage; QString errorMessage;
if (!reader.fetch(mainFilePath, &errorMessage)) { if (!reader.fetch(mainFilePath, &errorMessage)) {
Core::MessageManager::writeFlashing( Core::MessageManager::writeFlashing(
tr("Warning while loading project file %1.").arg(projectFilePath().toUserOutput())); Tr::tr("Warning while loading project file %1.").arg(projectFilePath().toUserOutput()));
Core::MessageManager::writeSilently(errorMessage); Core::MessageManager::writeSilently(errorMessage);
} }
} }

View File

@@ -197,7 +197,8 @@ Tasks QmlProject::projectIssues(const Kit *k) const
if (version->type() == QtSupport::Constants::DESKTOPQT) { if (version->type() == QtSupport::Constants::DESKTOPQT) {
if (version->qmlRuntimeFilePath().isEmpty()) { if (version->qmlRuntimeFilePath().isEmpty()) {
result.append( result.append(
createProjectTask(Task::TaskType::Error, tr("Qt version has no QML utility."))); createProjectTask(Task::TaskType::Error,
Tr::tr("Qt version has no QML utility.")));
} }
} else { } else {
// Non-desktop Qt on a desktop device? We don't support that. // Non-desktop Qt on a desktop device? We don't support that.

View File

@@ -498,7 +498,7 @@ public:
auto l = new QHBoxLayout(this); auto l = new QHBoxLayout(this);
for (const QnxTarget &target : config->m_targets) { for (const QnxTarget &target : config->m_targets) {
auto button = new QPushButton(tr("Create Kit for %1").arg(target.cpuDir())); auto button = new QPushButton(Tr::tr("Create Kit for %1").arg(target.cpuDir()));
connect(button, &QPushButton::clicked, this, [config, target] { connect(button, &QPushButton::clicked, this, [config, target] {
config->createKit(target); config->createKit(target);
}); });