[PC-BSD Commits] r1453 - pcbsd/trunk/NetworkTray

svn at pcbsd.org svn at pcbsd.org
Tue Feb 26 07:30:48 PST 2008


Author: kris
Date: 2008-02-26 07:30:48 -0800 (Tue, 26 Feb 2008)
New Revision: 1453

Modified:
   pcbsd/trunk/NetworkTray/main.cpp
Log:

Added translation support to the NetworkTray app



Modified: pcbsd/trunk/NetworkTray/main.cpp
===================================================================
--- pcbsd/trunk/NetworkTray/main.cpp	2008-02-26 15:23:43 UTC (rev 1452)
+++ pcbsd/trunk/NetworkTray/main.cpp	2008-02-26 15:30:48 UTC (rev 1453)
@@ -5,6 +5,7 @@
 #include <qtimer.h>
 #include <kcmdlineargs.h>
 #include <kuniqueapplication.h>
+#include <qtextcodec.h>
 
 #include <NetworkTray.h>
 
@@ -34,6 +35,12 @@
    KApplication  a;
 
    NetworkTray  tray;
+
+   QTranslator translator( 0 );
+   translator.load( QString("NetworkTray_") + QTextCodec::locale(), "/PCBSD/LANGS/" );
+   a.installTranslator( &translator );
+
+
    a.setMainWidget(&tray);
    a.connect(&a, SIGNAL(lastWindowClosed()), &a, SLOT(quit()));
 



More information about the Commits mailing list