[SCM] Kingston update notifier (update-notifier-kde) branch, master, updated. 723a1615b9ee75321e6f03961af561bf620700eb
Pino Toscano
pino-guest at alioth.debian.org
Wed May 12 21:20:01 UTC 2010
The following commit has been merged in the master branch:
commit ec17f4f8c1df2a5e12a99bc5c72eb5a89c47657e
Author: Pino Toscano <pino at kde.org>
Date: Wed May 12 23:10:07 2010 +0200
start adding i18n were necessary
although not complete yet (a couple of messages are missing), most of the visible strings should be convered
---
src/notifier.cpp | 15 ++++++++-------
1 files changed, 8 insertions(+), 7 deletions(-)
diff --git a/src/notifier.cpp b/src/notifier.cpp
index 6d9ec92..4388f4e 100644
--- a/src/notifier.cpp
+++ b/src/notifier.cpp
@@ -26,6 +26,7 @@
#include "notifier.h"
#include <KIcon>
+#include <KLocale>
#include <QApplication>
#include <QTimer>
@@ -49,12 +50,12 @@ void notifier_t::notify_new_updates(int updates, int security_updates) {
} else {
QPixmap px;
if(security_updates==0) {
- show_update_notification( "It is recommended to update your system", QString("There is %1 updates available").arg(updates), "dialog-information");
+ show_update_notification(i18n("It is recommended to update your system"), i18np("There is %1 update available", "There are %1 updates available", updates), "dialog-information");
} else {
if(updates==0) {
- show_update_notification( "You should update your system", QString("There is %1 security updates available").arg(security_updates), "dialog-warning");
+ show_update_notification(i18n("You should update your system"), i18np("There is %1 security update available", "There are %1 security updates available", security_updates==0), "dialog-warning");
} else {
- show_update_notification( "You should update your system", QString("There is %1 updates and %2 security updates available").arg(updates).arg(security_updates), "dialog-warning" );
+ show_update_notification(i18n("You should update your system"), QString("There is %1 updates and %2 security updates available").arg(updates).arg(security_updates), "dialog-warning" );
}
}
@@ -67,7 +68,7 @@ void notifier_t::show_update_notification(const QString& title, const QString& m
note->setText(message);
note->setPixmap(KIcon(iconname).pixmap(QSize(32,32)));
note->setComponentData(*m_component_data);
- note->setActions(QStringList() << "Later");
+ note->setActions(QStringList() << i18nc("Reboot later", "Later"));
connect(note,SIGNAL(activated()),note,SLOT(close()));
note->sendEvent();
return;
@@ -75,11 +76,11 @@ void notifier_t::show_update_notification(const QString& title, const QString& m
void notifier_t::notify_reboot() {
KNotification* note = new KNotification("requestreboot",0L, KNotification::Persistent);
- note->setTitle("Please reboot your system");
- note->setText("In order to complete this upgrade, you need to reboot your system");
+ note->setTitle(i18n("Please reboot your system"));
+ note->setText(i18n("In order to complete this upgrade, you need to reboot your system"));
note->setPixmap(KIcon("system-reboot").pixmap(QSize(32,32)));
note->setComponentData(*m_component_data);
- note->setActions(QStringList() << "Later");
+ note->setActions(QStringList() << i18nc("Reboot later", "Later"));
connect(note,SIGNAL(closed()),m_reboot_nagger,SLOT(start()));
connect(note,SIGNAL(action1Activated()),m_reboot_nagger,SLOT(start()));
note->sendEvent();
--
Kingston update notifier (update-notifier-kde)
More information about the pkg-kde-commits
mailing list