Fix translation typos and missing Q_OBJECT macro

This commit is contained in:
Filippo Gentile 2023-02-18 19:46:21 +01:00
parent 6923642a53
commit 9bf0027fe3
4 changed files with 5 additions and 4 deletions

View File

@ -51,7 +51,7 @@ BackgroundResultWidget::BackgroundResultWidget(IBackgroundChecker *mgr_, QWidget
view->setContextMenuPolicy(Qt::CustomContextMenu);
connect(view, &QTreeView::customContextMenuRequested, this, &BackgroundResultWidget::showContextMenu);
setWindowTitle(tr("Rollingstock Errors"));
setWindowTitle(tr("Error Results"));
progressBar->hide();
}

View File

@ -9,6 +9,7 @@
class JobCrossingChecker : public IBackgroundChecker
{
Q_OBJECT
public:
JobCrossingChecker(sqlite3pp::database &db, QObject *parent = nullptr);

View File

@ -8,7 +8,7 @@ static const char* error_texts[] = {
QT_TRANSLATE_NOOP("JobErrors", "Job passes another Job on same track.")
};
class JobError
class JobErrors
{
Q_DECLARE_TR_FUNCTIONS(JobErrors)
};
@ -61,7 +61,7 @@ QVariant JobCrossingModel::data(const QModelIndex &idx, int role) const
case Departure:
return item->departure;
case Description:
return JobError::tr(error_texts[item->type]);
return JobErrors::tr(error_texts[item->type]);
default:
break;
}

View File

@ -737,7 +737,7 @@ void StationEditDialog::importConnFromSVG()
}
else
{
QMessageBox::warning(this, tr("Import Errpr"),
QMessageBox::warning(this, tr("Import Error"),
tr("Generic error"));
}