-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.cpp
More file actions
51 lines (38 loc) · 851 Bytes
/
main.cpp
File metadata and controls
51 lines (38 loc) · 851 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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
#include <QtGui>
#include <QApplication>
#include "mainwindow.h"
int main(int argc, char *argv[])
{
QApplication a(argc, argv);
QString version = "0.0.1";
QDir d1 = QDir();
QString appDir;
#ifdef Q_OS_WIN
//qDebug() << "WINDOWS DETECTED!" << endl;
appDir = QDir::homePath()+"/kluster"; // We create the \kluster for the logs and data
#else
//qDebug() << "NO WINDOWS DETECTED!" << endl;
appDir = QDir::homePath()+"/.kluster"; // We create the ~/.kluster
#endif
if (!QDir::setCurrent (appDir) )
{
if (d1.mkdir(appDir))
{
if (QDir::setCurrent (appDir) )
{
}
else
{
}
}
else
{
}
}
else
{
}
MainWindow w(appDir, version);
w.show();
return a.exec();
}