-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.cpp
More file actions
49 lines (46 loc) · 1.15 KB
/
main.cpp
File metadata and controls
49 lines (46 loc) · 1.15 KB
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
#include <QCoreApplication>
#include <QApplication>
#ifdef KDE5
#include <QCommandLineParser>
#endif
#include "gui/mainwindow.h"
#include <klocalizedstring.h>
#include <kaboutdata.h>
#include "base/globals.h"
#include <KSharedConfig>
#include <KConfigGroup>
#include "base/version.h"
#include "base/config.h"
int main(int argc, char **argv) {
g_app=new QApplication(argc,argv);
//TODO to KDE4
#ifdef KDE5
KLocalizedString::setApplicationDomain(PROG_NAME);
KAboutData l_aboutData(
PROG_NAME
, i18n("Disk information gui")
, VERSION
, i18n("X")
, KAboutLicense::GPL
, i18n("(C) 2016..2022")
, i18n("x")
, QStringLiteral("X")
, QStringLiteral("X")
);
l_aboutData.addAuthor(i18n("Jeroen van Iddekinge"),i18n("X"),("iddekingej@lycos.com"));
KAboutData::setApplicationData(l_aboutData);
QCommandLineParser l_parser;
l_parser.addHelpOption();
l_parser.addVersionOption();
l_aboutData.setupCommandLine(&l_parser);
l_parser.process(*g_app);
l_aboutData.processCommandLine(&l_parser);
#endif
g_config.setup();
TMainWindow *l_main=new TMainWindow();
l_main->show();
int l_exit=g_app->exec();
delete l_main;
delete g_app;
return l_exit;
}