-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.cpp
More file actions
33 lines (25 loc) · 743 Bytes
/
main.cpp
File metadata and controls
33 lines (25 loc) · 743 Bytes
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
#include <QtGui>
#include <QApplication>
#include "appw.h"
int main(int argc, char *argv[])
{
// if we have a resource file: Q_INIT_RESOURCE(app)
QString locale = QLocale::system().name();
QTranslator translator;
translator.load(QString("pxv_") + locale);
QApplication app(argc, argv); // on return it is the filtered list
// app.setOrganizationName("LF"); // needed for QSettings?
app.setApplicationName("pxv"); // used by QSettings
app.installTranslator(&translator);
app.setWindowIcon(QIcon(":/pxv.svg"));
AppWindow appw;
if (argc > 0)
{
for (int i = 1; i < argc; ++i)
{
appw.setDataFile(argv[i],"");
}
}
appw.show();
return app.exec();
}