Android: Remove html code from tr-strings in keystore creation dialog

This change removes markup with its unthemed color values from
translatable strings. Terminates error messages with a ".". Adjusts the
message strings in the .ts files, accordingly.

The error label is changed from QLabel to Utils::InfoLabel.

Change-Id: Ifdd65de8d9e0ae311b494e70b9dc77ca0a3e4f46
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Robert Löhning <robert.loehning@qt.io>
This commit is contained in:
Alessandro Portale
2022-01-29 00:36:49 +01:00
parent d5eed0480d
commit e58f50df2a
11 changed files with 128 additions and 119 deletions

View File

@@ -54911,28 +54911,28 @@ Nainstalujte, prosím, jedno SDK s API verze alespoň %1.</translation>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Heslo je OK&lt;/span&gt;</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Keystore password is too short&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Heslo k úložišti klíče je příliš krátké&lt;/span&gt;</translation>
<source>Keystore password is too short.</source>
<translation>Heslo k úložišti klíče je příliš krátké.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Keystore passwords do not match&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Hesla k úložišti klíče neodpovídají&lt;/span&gt;</translation>
<source>Keystore passwords do not match.</source>
<translation>Hesla k úložišti klíče neodpovídají.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certificate password is too short&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Heslo k certifikátu je příliš krátké&lt;/span&gt;</translation>
<source>Certificate password is too short.</source>
<translation>Heslo k certifikátu je příliš krátké.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certificate passwords do not match&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Hesla k certifikátům neodpovídají&lt;/span&gt;</translation>
<source>Certificate passwords do not match.</source>
<translation>Hesla k certifikátům neodpovídají.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certificate alias is missing&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Alias certifikátu chybí&lt;/span&gt;</translation>
<source>Certificate alias is missing.</source>
<translation>Alias certifikátu chybí.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Invalid country code&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Neplatné číslo země (mezinárodní předvolba)&lt;/span&gt;</translation>
<source>Invalid country code.</source>
<translation>Neplatné číslo země (mezinárodní předvolba).</translation>
</message>
<message>
<source>Keystore file name</source>

View File

@@ -268,28 +268,28 @@ Minimum API-niveauet krævet af kittet er %1.</translation>
<context>
<name>Android::Internal::AndroidCreateKeystoreCertificate</name>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Keystore password is too short&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Keystore adgangskode er for kort&lt;/span&gt;</translation>
<source>Keystore password is too short.</source>
<translation>Keystore adgangskode er for kort.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Keystore passwords do not match&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Keystore adgangskoder matcher ikke&lt;/span&gt;</translation>
<source>Keystore passwords do not match.</source>
<translation>Keystore adgangskoder matcher ikke.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certificate password is too short&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certifikat adgangskode er for kort&lt;/span&gt;</translation>
<source>Certificate password is too short.</source>
<translation>Certifikat adgangskode er for kort.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certificate passwords do not match&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certifikat adgangskoder matcher ikke&lt;/span&gt;</translation>
<source>Certificate passwords do not match.</source>
<translation>Certifikat adgangskoder matcher ikke.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certificate alias is missing&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certifikat-alias mangler&lt;/span&gt;</translation>
<source>Certificate alias is missing.</source>
<translation>Certifikat-alias mangler.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Invalid country code&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Ugyldig sprogkode&lt;/span&gt;</translation>
<source>Invalid country code.</source>
<translation>Ugyldig sprogkode.</translation>
</message>
<message>
<source>Keystore Filename</source>

View File

@@ -19510,28 +19510,28 @@ should a repository require SSH-authentication (see documentation on SSH and the
<context>
<name>Android::Internal::AndroidCreateKeystoreCertificate</name>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Keystore password is too short&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Das Keystore-Passwort ist zu kurz&lt;/span&gt;</translation>
<source>Keystore password is too short.</source>
<translation>Das Keystore-Passwort ist zu kurz.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Keystore passwords do not match&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Die Keystore-Passwörter stimmen nicht überein&lt;/span&gt;</translation>
<source>Keystore passwords do not match.</source>
<translation>Die Keystore-Passwörter stimmen nicht überein.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certificate password is too short&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Das Passwort des Zertifikats ist zu kurz&lt;/span&gt;</translation>
<source>Certificate password is too short.</source>
<translation>Das Passwort des Zertifikats ist zu kurz.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certificate passwords do not match&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Die Passwörter des Zertifikats stimmen nicht überein&lt;/span&gt;</translation>
<source>Certificate passwords do not match.</source>
<translation>Die Passwörter des Zertifikats stimmen nicht überein.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certificate alias is missing&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Der Alias des Zertifikats fehlt&lt;/span&gt;</translation>
<source>Certificate alias is missing.</source>
<translation>Der Alias des Zertifikats fehlt.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Invalid country code&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Ungültiger Ländercode&lt;/span&gt;</translation>
<source>Invalid country code.</source>
<translation>Ungültiger Ländercode.</translation>
</message>
<message>
<source>Keystore Filename</source>

View File

@@ -60828,28 +60828,28 @@ Veuillez installer un SDK supérieur à la version %1.</translation>
<translation>&lt;span style=&quot; color:#00ff00;&quot;&gt;Mot de passe correct&lt;/span&gt;</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Keystore password is too short&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Le mot de passe du trousseau de clés est trop court&lt;/span&gt;</translation>
<source>Keystore password is too short.</source>
<translation>Le mot de passe du trousseau de clés est trop court.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Keystore passwords do not match&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Les mots de passe du trousseau de clés ne correspondent pas&lt;/span&gt;</translation>
<source>Keystore passwords do not match.</source>
<translation>Les mots de passe du trousseau de clés ne correspondent pas.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certificate password is too short&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Le mot de passe du certificat est manquant&lt;/span&gt;</translation>
<source>Certificate password is too short.</source>
<translation>Le mot de passe du certificat est manquant.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certificate passwords do not match&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Les mots de passe du certificat ne correspondent pas&lt;/span&gt;</translation>
<source>Certificate passwords do not match.</source>
<translation>Les mots de passe du certificat ne correspondent pas.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certificate alias is missing&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;L&apos;alias du certificat est manquant&lt;/span&gt;</translation>
<source>Certificate alias is missing.</source>
<translation>L&apos;alias du certificat est manquant.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Invalid country code&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Le code de pays est invalide&lt;/span&gt;</translation>
<source>Invalid country code.</source>
<translation>Le code de pays est invalide.</translation>
</message>
<message>
<source>Keystore file name</source>

View File

@@ -14265,27 +14265,27 @@ The minimum API level required by the kit is %1.</source>
<context>
<name>Android::Internal::AndroidCreateKeystoreCertificate</name>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Keystore password is too short&lt;/span&gt;</source>
<source>Keystore password is too short.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Keystore passwords do not match&lt;/span&gt;</source>
<source>Keystore passwords do not match.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certificate password is too short&lt;/span&gt;</source>
<source>Certificate password is too short.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certificate passwords do not match&lt;/span&gt;</source>
<source>Certificate passwords do not match.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certificate alias is missing&lt;/span&gt;</source>
<source>Certificate alias is missing.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Invalid country code&lt;/span&gt;</source>
<source>Invalid country code.</source>
<translation type="unfinished"></translation>
</message>
<message>

View File

@@ -9625,28 +9625,28 @@ with a password, which you can enter below.</source>
<context>
<name>Android::Internal::AndroidCreateKeystoreCertificate</name>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Keystore password is too short&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;&lt;/span&gt;</translation>
<source>Keystore password is too short.</source>
<translation></translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Keystore passwords do not match&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;&lt;/span&gt;</translation>
<source>Keystore passwords do not match.</source>
<translation></translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certificate password is too short&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;&lt;/span&gt;</translation>
<source>Certificate password is too short.</source>
<translation></translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certificate passwords do not match&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;&lt;/span&gt;</translation>
<source>Certificate passwords do not match.</source>
<translation></translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certificate alias is missing&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;&lt;/span&gt;</translation>
<source>Certificate alias is missing.</source>
<translation></translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Invalid country code&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;&lt;/span&gt;</translation>
<source>Invalid country code.</source>
<translation></translation>
</message>
<message>
<source>Keystore file name</source>

View File

@@ -21525,28 +21525,28 @@ Sprawdź dokumentację SSH i zmienną środowiskową SSH_ASKPASS.</translation>
<context>
<name>Android::Internal::AndroidCreateKeystoreCertificate</name>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Keystore password is too short&lt;/span&gt;</source>
<source>Keystore password is too short.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Keystore passwords do not match&lt;/span&gt;</source>
<source>Keystore passwords do not match.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certificate password is too short&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Hasło certyfikatu jest zbyt krótkie&lt;/span&gt;</translation>
<source>Certificate password is too short.</source>
<translation>Hasło certyfikatu jest zbyt krótkie.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certificate passwords do not match&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Hasła certyfikatu nie zgadzają się&lt;/span&gt;</translation>
<source>Certificate passwords do not match.</source>
<translation>Hasła certyfikatu nie zgadzają się.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certificate alias is missing&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Brak aliasu certyfikatu&lt;/span&gt;</translation>
<source>Certificate alias is missing.</source>
<translation>Brak aliasu certyfikatu.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Invalid country code&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Niepoprawny kod kraju&lt;/span&gt;</translation>
<source>Invalid country code.</source>
<translation>Niepoprawny kod kraju.</translation>
</message>
<message>
<source>Keystore Filename</source>

View File

@@ -887,28 +887,28 @@ The files in the Android package source directory are copied to the build direct
<context>
<name>Android::Internal::AndroidCreateKeystoreCertificate</name>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Keystore password is too short&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Пароль связки ключей слишком короткий&lt;/span&gt;</translation>
<source>Keystore password is too short.</source>
<translation>Пароль связки ключей слишком короткий.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Keystore passwords do not match&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Неверный пароль связки ключей&lt;/span&gt;</translation>
<source>Keystore passwords do not match.</source>
<translation>Неверный пароль связки ключей.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certificate password is too short&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Пароль сертификата слишком короткий&lt;/span&gt;</translation>
<source>Certificate password is too short.</source>
<translation>Пароль сертификата слишком короткий.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certificate passwords do not match&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Неверный пароль сертификата&lt;/span&gt;</translation>
<source>Certificate passwords do not match.</source>
<translation>Неверный пароль сертификата.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certificate alias is missing&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Отсутствует алиас сертификата&lt;/span&gt;</translation>
<source>Certificate alias is missing.</source>
<translation>Отсутствует алиас сертификата.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Invalid country code&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Неверный код страны&lt;/span&gt;</translation>
<source>Invalid country code.</source>
<translation>Неверный код страны.</translation>
</message>
<message>
<source>Keystore Filename</source>

View File

@@ -32522,28 +32522,28 @@ Please install an SDK of at least API version %1.</source>
<translation type="vanished">&lt;span style=&quot; color:#00ff00;&quot;&gt;Пароль вдалий&lt;/span&gt;</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Keystore password is too short&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Пароль сховища ключів закороткий&lt;/span&gt;</translation>
<source>Keystore password is too short.</source>
<translation>Пароль сховища ключів закороткий.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Keystore passwords do not match&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Паролі сховища ключів не співпадають&lt;/span&gt;</translation>
<source>Keystore passwords do not match.</source>
<translation>Паролі сховища ключів не співпадають.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certificate password is too short&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Пароль сертифіката закороткий&lt;/span&gt;</translation>
<source>Certificate password is too short.</source>
<translation>Пароль сертифіката закороткий.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certificate passwords do not match&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Паролі сертифіката не співпадають&lt;/span&gt;</translation>
<source>Certificate passwords do not match.</source>
<translation>Паролі сертифіката не співпадають.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Certificate alias is missing&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Відсутній псевдонім сертифіката&lt;/span&gt;</translation>
<source>Certificate alias is missing.</source>
<translation>Відсутній псевдонім сертифіката.</translation>
</message>
<message>
<source>&lt;span style=&quot; color:#ff0000;&quot;&gt;Invalid country code&lt;/span&gt;</source>
<translation>&lt;span style=&quot; color:#ff0000;&quot;&gt;Неправильний код країни&lt;/span&gt;</translation>
<source>Invalid country code.</source>
<translation>Неправильний код країни.</translation>
</message>
<message>
<source>Keystore file name</source>

View File

@@ -42,6 +42,9 @@ AndroidCreateKeystoreCertificate::AndroidCreateKeystoreCertificate(QWidget *pare
ui(new Ui::AndroidCreateKeystoreCertificate)
{
ui->setupUi(this);
ui->infoLabel->setType(InfoLabel::Error);
ui->infoLabel->hide();
connect(ui->keystorePassLineEdit, &QLineEdit::textChanged,
this, &AndroidCreateKeystoreCertificate::checkKeystorePassword);
connect(ui->keystoreRetypePassLineEdit, &QLineEdit::textChanged,
@@ -100,15 +103,17 @@ QString AndroidCreateKeystoreCertificate::certificatePassword()
AndroidCreateKeystoreCertificate::PasswordStatus AndroidCreateKeystoreCertificate::checkKeystorePassword()
{
if (ui->keystorePassLineEdit->text().length() < 6) {
ui->infoLabel->setText(tr("<span style=\" color:#ff0000;\">Keystore password is too short</span>"));
ui->infoLabel->show();
ui->infoLabel->setText(tr("Keystore password is too short."));
return Invalid;
}
if (ui->keystorePassLineEdit->text() != ui->keystoreRetypePassLineEdit->text()) {
ui->infoLabel->setText(tr("<span style=\" color:#ff0000;\">Keystore passwords do not match</span>"));
ui->infoLabel->show();
ui->infoLabel->setText(tr("Keystore passwords do not match."));
return NoMatch;
}
ui->infoLabel->clear();
ui->infoLabel->hide();
return Match;
}
@@ -118,37 +123,41 @@ AndroidCreateKeystoreCertificate::PasswordStatus AndroidCreateKeystoreCertificat
return Match;
if (ui->certificatePassLineEdit->text().length() < 6) {
ui->infoLabel->setText(tr("<span style=\" color:#ff0000;\">Certificate password is too short</span>"));
ui->infoLabel->show();
ui->infoLabel->setText(tr("Certificate password is too short."));
return Invalid;
}
if (ui->certificatePassLineEdit->text() != ui->certificateRetypePassLineEdit->text()) {
ui->infoLabel->setText(tr("<span style=\" color:#ff0000;\">Certificate passwords do not match</span>"));
ui->infoLabel->show();
ui->infoLabel->setText(tr("Certificate passwords do not match."));
return NoMatch;
}
ui->infoLabel->clear();
ui->infoLabel->hide();
return Match;
}
bool AndroidCreateKeystoreCertificate::checkCertificateAlias()
{
if (ui->certificateAliasLineEdit->text().length() == 0) {
ui->infoLabel->setText(tr("<span style=\" color:#ff0000;\">Certificate alias is missing</span>"));
ui->infoLabel->show();
ui->infoLabel->setText(tr("Certificate alias is missing."));
return false;
}
ui->infoLabel->clear();
ui->infoLabel->hide();
return true;
}
bool AndroidCreateKeystoreCertificate::checkCountryCode()
{
if (!ui->countryLineEdit->text().contains(QRegularExpression("[A-Z]{2}"))) {
ui->infoLabel->setText(tr("<span style=\" color:#ff0000;\">Invalid country code</span>"));
ui->infoLabel->show();
ui->infoLabel->setText(tr("Invalid country code."));
return false;
}
ui->infoLabel->clear();
ui->infoLabel->hide();
return true;
}

View File

@@ -299,17 +299,17 @@
</widget>
</item>
<item row="3" column="0">
<widget class="QLabel" name="infoLabel">
<property name="text">
<string/>
</property>
<property name="alignment">
<set>Qt::AlignCenter</set>
</property>
</widget>
<widget class="Utils::InfoLabel" name="infoLabel"/>
</item>
</layout>
</widget>
<customwidgets>
<customwidget>
<class>Utils::InfoLabel</class>
<extends>QLabel</extends>
<header location="global">utils/infolabel.h</header>
</customwidget>
</customwidgets>
<tabstops>
<tabstop>keystorePassLineEdit</tabstop>
<tabstop>keystoreRetypePassLineEdit</tabstop>