25 lines
621 B
C++
25 lines
621 B
C++
#include "mainwindow.h"
|
|
|
|
#include <QTranslator>
|
|
|
|
int main(int argc, char *argv[])
|
|
{
|
|
QApplication a(argc, argv);
|
|
QTranslator myappTranslator;
|
|
|
|
QCoreApplication::setOrganizationName("RsyncUI");
|
|
QCoreApplication::setApplicationName("RsyncUI");
|
|
|
|
// Initialization of localization
|
|
QLocale localeName = QLocale::system();
|
|
QString localeFile = "/usr/share/locale/" + localeName.name() + "/LC_MESSAGES/RsyncUI_" + localeName.name() + ".qm";
|
|
if (myappTranslator.load(localeFile))
|
|
{
|
|
a.installTranslator(&myappTranslator);
|
|
}
|
|
|
|
MainWindow w;
|
|
w.show();
|
|
return a.exec();
|
|
}
|