-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.cpp
33 lines (27 loc) · 887 Bytes
/
main.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
/*
* 2015 © Steve Dodier-Lazaro <[email protected]>
* Under the GNU Affero GPL3 License
*/
#include "UI/mainwindow.h"
#include "study.h"
#include <QApplication>
#include <QTranslator>
#include <QLibraryInfo>
#include <iostream>
int main(int argc, char *argv[])
{
QApplication a(argc, argv);
StudyUtils::init();
QTranslator qtTranslator;
qtTranslator.load("qt_" + QLocale::system().name(), QLibraryInfo::location(QLibraryInfo::TranslationsPath));
a.installTranslator(&qtTranslator);
QTranslator myappTranslator;
myappTranslator.load("study_" + QLocale::system().name());
a.installTranslator(&myappTranslator);
// Make absolutely certain that we register at least the starting date for part 1
StudyUtils *utils = StudyUtils::getUtils();
utils->registerInstall(Part::fromId(1));
MainWindow w;
w.show();
return a.exec();
}