From fe5dac7496cee3c5474cd8e5043d33f6e45e742e Mon Sep 17 00:00:00 2001 From: Philipp Spitzer Date: Mon, 23 Jan 2017 21:47:40 +0100 Subject: [PATCH] Used tr() for some more GUI strings (there are plenty more that should be treated this way). --- src/gui/mainwindow.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/gui/mainwindow.cpp b/src/gui/mainwindow.cpp index 556f6c7..98a45c8 100644 --- a/src/gui/mainwindow.cpp +++ b/src/gui/mainwindow.cpp @@ -271,7 +271,7 @@ void MainWindow::onAlarmTimerTimeout() { // show message systemTrayIcon->show(); // The next two lines are to prevent a very strange position of the message box the first time at X11/aweseome (not Win32/XP) - systemTrayIcon->showMessage("ConfClerk", "Your upcoming events", QSystemTrayIcon::Information); + systemTrayIcon->showMessage("ConfClerk", tr("Your upcoming events"), QSystemTrayIcon::Information); qApp->processEvents(); systemTrayIcon->showMessage(title, message, QSystemTrayIcon::Information, 60*60*24*1000); QApplication::alert(this); @@ -432,7 +432,7 @@ void MainWindow::sslErrors(QNetworkReply *aReply, const QList &errors void MainWindow::networkQueryFinished(QNetworkReply *aReply) { if (aReply->error() != QNetworkReply::NoError) { - error_message(QString("Error occurred during download: ") + aReply->errorString()); + error_message(tr("Error occurred during download: %1").arg(aReply->errorString())); } else { QUrl redirectUrl = aReply->attribute(QNetworkRequest::RedirectionTargetAttribute).toUrl(); if (!redirectUrl.isEmpty()) { @@ -440,7 +440,7 @@ void MainWindow::networkQueryFinished(QNetworkReply *aReply) { importFromNetwork(redirectUrl.toString(), aReply->request().attribute(QNetworkRequest::User).toInt()); return; // don't enable controls } else { - error_message(QString("Error: Cyclic redirection from %1 to itself.").arg(redirectUrl.toString())); + error_message(tr("Error: Cyclic redirection from %1 to itself.").arg(redirectUrl.toString())); } } else { importData(aReply->readAll(), aReply->url().toEncoded(), aReply->request().attribute(QNetworkRequest::User).toInt()); -- 2.39.5