-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathmain.cpp
33 lines (23 loc) · 849 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
#include <QApplication>
#include <QtWebEngineQuick/qtwebenginequickglobal.h>
#include "overlay.h"
#include "systray.h"
#include "configuredialogue.h"
int main(int argc, char *argv[])
{
QtWebEngineQuick::initialize();
QApplication app(argc, argv);
QCoreApplication::addLibraryPath("lib");
app.setQuitOnLastWindowClosed(false);
app.setApplicationName("TwitchOverlay");
app.setOrganizationName("TwitchOverlay");
Overlay o(0);
o.show();
Systray s;
QObject::connect( &s, SIGNAL(toggle()), &o, SLOT(toggle()) );
QObject::connect( &s, SIGNAL(openReposition()), &o, SLOT(reposition()) );
QObject::connect( &o, SIGNAL(_showMessage(QString)), &s, SLOT(showMessage(QString)) );
ConfigureDialogue cd(&o);
QObject::connect( &s, SIGNAL(openConfig()), &cd, SLOT(show()) );
return app.exec();
}