Rabbit Remote Control 0.0.30
Loading...
Searching...
No Matches
main.cpp
1#include "mainwindow.h"
2
3#include <QApplication>
4#include <QLocale>
5#include <QTranslator>
6
7int main(int argc, char *argv[])
8{
9 QApplication a(argc, argv);
10
11 QTranslator translator;
12 const QStringList uiLanguages = QLocale::system().uiLanguages();
13 for (const QString &locale : uiLanguages) {
14 const QString baseName = "Display_" + QLocale(locale).name();
15 if (translator.load(":/i18n/" + baseName)) {
16 a.installTranslator(&translator);
17 break;
18 }
19 }
20 MainWindow w;
21 w.show();
22 return a.exec();
23}
The MainWindow class.
Definition mainwindow.h:32