From 3eef4bd12b8ba48145eb14300f202a0616f3b5e2 Mon Sep 17 00:00:00 2001 From: Christian Hohnstaedt Date: Tue, 27 Mar 2018 18:30:07 +0200 Subject: [PATCH] Fix translation artefacts. No need to translate "X Certificate and Key management", "Form", "Dialog" or "TimeInput" "Select Token" and "New Key" window titles were never shown. Remove them. --- lib/pkcs11.cpp | 1 + lib/sql.h | 2 +- ui/ItemProperties.ui | 2 +- ui/NewCrl.ui | 2 +- ui/NewKey.ui | 2 +- ui/SearchPkcs11.ui | 2 +- ui/SelectToken.ui | 2 +- ui/TimeInput.ui | 2 +- widgets/CrlDetail.cpp | 2 +- widgets/KeyDetail.cpp | 2 +- widgets/KeyTreeView.cpp | 2 +- widgets/MW_help.cpp | 2 +- widgets/NewKey.cpp | 2 +- widgets/OidResolver.cpp | 2 +- widgets/TempTreeView.cpp | 2 +- 15 files changed, 15 insertions(+), 14 deletions(-) diff --git a/lib/pkcs11.cpp b/lib/pkcs11.cpp index af850e02..86d52134 100644 --- a/lib/pkcs11.cpp +++ b/lib/pkcs11.cpp @@ -304,6 +304,7 @@ bool pkcs11::selectToken(slotid *slot, QWidget *w) ui.image->setPixmap(*MainWindow::scardImg); ui.tokenBox->addItems(slotnames); ui.buttonBox->button(QDialogButtonBox::Ok)->setText(QObject::tr("Select")); + select_slot->setWindowTitle(XCA_TITLE); if (select_slot->exec() == 0) { delete select_slot; return false; diff --git a/lib/sql.h b/lib/sql.h index 87239af8..3303ccf7 100644 --- a/lib/sql.h +++ b/lib/sql.h @@ -51,7 +51,7 @@ class DbTransaction #define Transaction DbTransaction __trans #define TransBegin() __trans.begin(__FILE__, __LINE__) #define TransThrow() if (!__trans.begin(__FILE__, __LINE__)) { \ - throw errorEx(tr("Failed to start a database transaction")); } + throw errorEx(QObject::tr("Failed to start a database transaction")); } #define TransCommit() __trans.commit(__FILE__, __LINE__) #define TransRollback() __trans.rollback(__FILE__, __LINE__) #define TransDone(e) __trans.done(e, __FILE__, __LINE__); diff --git a/ui/ItemProperties.ui b/ui/ItemProperties.ui index 475a1b8e..98112950 100644 --- a/ui/ItemProperties.ui +++ b/ui/ItemProperties.ui @@ -11,7 +11,7 @@ - Form + diff --git a/ui/NewCrl.ui b/ui/NewCrl.ui index 935ba839..c4eb8bb2 100644 --- a/ui/NewCrl.ui +++ b/ui/NewCrl.ui @@ -11,7 +11,7 @@ - Form + diff --git a/ui/NewKey.ui b/ui/NewKey.ui index 6bcad35e..406df3af 100644 --- a/ui/NewKey.ui +++ b/ui/NewKey.ui @@ -11,7 +11,7 @@ - New Key + diff --git a/ui/SearchPkcs11.ui b/ui/SearchPkcs11.ui index 7f17fbbe..85872518 100644 --- a/ui/SearchPkcs11.ui +++ b/ui/SearchPkcs11.ui @@ -11,7 +11,7 @@ - Dialog + diff --git a/ui/SelectToken.ui b/ui/SelectToken.ui index 36304daa..c090996f 100644 --- a/ui/SelectToken.ui +++ b/ui/SelectToken.ui @@ -11,7 +11,7 @@ - Select Token + diff --git a/ui/TimeInput.ui b/ui/TimeInput.ui index 258ce7de..3bdfaa14 100644 --- a/ui/TimeInput.ui +++ b/ui/TimeInput.ui @@ -11,7 +11,7 @@ - TimeInput + diff --git a/widgets/CrlDetail.cpp b/widgets/CrlDetail.cpp index a585d812..142b33da 100644 --- a/widgets/CrlDetail.cpp +++ b/widgets/CrlDetail.cpp @@ -22,7 +22,7 @@ CrlDetail::CrlDetail(MainWindow *mainwin) { mw = mainwin; setupUi(this); - setWindowTitle(tr(XCA_TITLE)); + setWindowTitle(XCA_TITLE); image->setPixmap(*MainWindow::revImg); issuerSqlId = QVariant(); diff --git a/widgets/KeyDetail.cpp b/widgets/KeyDetail.cpp index 5f338a4b..18ca1007 100644 --- a/widgets/KeyDetail.cpp +++ b/widgets/KeyDetail.cpp @@ -21,7 +21,7 @@ KeyDetail::KeyDetail(QWidget *parent) :QDialog(parent) { setupUi(this); - setWindowTitle(tr(XCA_TITLE)); + setWindowTitle(XCA_TITLE); image->setPixmap(*MainWindow::keyImg); keyModulus->setFont(XCA_application::tableFont); tabWidget->setCurrentIndex(0); diff --git a/widgets/KeyTreeView.cpp b/widgets/KeyTreeView.cpp index c381f2d3..ef27305c 100644 --- a/widgets/KeyTreeView.cpp +++ b/widgets/KeyTreeView.cpp @@ -6,7 +6,7 @@ */ #include "lib/pki_scard.h" -#include "XcaTreeView.h" +#include "KeyTreeView.h" #include "MainWindow.h" #include #include diff --git a/widgets/MW_help.cpp b/widgets/MW_help.cpp index 57676cab..68b7473b 100644 --- a/widgets/MW_help.cpp +++ b/widgets/MW_help.cpp @@ -129,7 +129,7 @@ void MainWindow::help() ui.textbox->setSource(QUrl(uri)); ui.textbox->setSearchPaths(QStringList(path)); - h->setWindowTitle(tr(XCA_TITLE)); + h->setWindowTitle(XCA_TITLE); h->show(); } diff --git a/widgets/NewKey.cpp b/widgets/NewKey.cpp index cd28f3e6..893c3122 100644 --- a/widgets/NewKey.cpp +++ b/widgets/NewKey.cpp @@ -130,7 +130,7 @@ NewKey::NewKey(QWidget *parent, QString name) QList keytypes; setupUi(this); - setWindowTitle(tr(XCA_TITLE)); + setWindowTitle(XCA_TITLE); image->setPixmap(*MainWindow::keyImg); if (!name.isEmpty()) diff --git a/widgets/OidResolver.cpp b/widgets/OidResolver.cpp index fa954256..dde5c77b 100644 --- a/widgets/OidResolver.cpp +++ b/widgets/OidResolver.cpp @@ -15,8 +15,8 @@ OidResolver::OidResolver(QWidget *parent) :QWidget(parent) { - setWindowTitle(tr(XCA_TITLE)); setupUi(this); + setWindowTitle(XCA_TITLE); } void OidResolver::searchOid(QString s) diff --git a/widgets/TempTreeView.cpp b/widgets/TempTreeView.cpp index 7c5e724a..5f879b90 100644 --- a/widgets/TempTreeView.cpp +++ b/widgets/TempTreeView.cpp @@ -6,7 +6,7 @@ */ #include "lib/pki_temp.h" -#include "XcaTreeView.h" +#include "TempTreeView.h" #include "MainWindow.h" #include #include