DONT TAKE, BROKEN! first application of delay manager in code, reception of bundles
This commit is contained in:
parent
5ba97ecc25
commit
927bdf0dab
16 changed files with 261 additions and 139 deletions
|
@ -16,6 +16,7 @@
|
|||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include "root.h"
|
||||
#include "shared/global.h"
|
||||
#include "shared/messageinfo.h"
|
||||
#include "shared/pathcheck.h"
|
||||
|
@ -31,7 +32,6 @@
|
|||
#include <QTranslator>
|
||||
#include <QtCore/QObject>
|
||||
#include <QtCore/QThread>
|
||||
#include <QtWidgets/QApplication>
|
||||
#include <QDir>
|
||||
|
||||
#ifdef WITH_OMEMO
|
||||
|
@ -59,13 +59,13 @@ int main(int argc, char *argv[])
|
|||
qRegisterMetaType<QXmppOmemoStorage::Device>("QXmppOmemoStorage::Device");
|
||||
#endif
|
||||
|
||||
QApplication app(argc, argv);
|
||||
Root app(argc, argv);
|
||||
SignalCatcher sc(&app);
|
||||
|
||||
QApplication::setApplicationName("squawk");
|
||||
QApplication::setOrganizationName("macaw.me");
|
||||
QApplication::setApplicationDisplayName("Squawk");
|
||||
QApplication::setApplicationVersion("0.2.3");
|
||||
Root::setApplicationName("squawk");
|
||||
Root::setOrganizationName("macaw.me");
|
||||
Root::setApplicationDisplayName("Squawk");
|
||||
Root::setApplicationVersion("0.2.3");
|
||||
app.setDesktopFileName("squawk");
|
||||
|
||||
QTranslator qtTranslator;
|
||||
|
@ -97,7 +97,7 @@ int main(int argc, char *argv[])
|
|||
icon.addFile(":images/logo.svg", QSize(128, 128));
|
||||
icon.addFile(":images/logo.svg", QSize(256, 256));
|
||||
icon.addFile(":images/logo.svg", QSize(512, 512));
|
||||
QApplication::setWindowIcon(icon);
|
||||
Root::setWindowIcon(icon);
|
||||
|
||||
new Shared::Global(); //translates enums
|
||||
|
||||
|
@ -139,7 +139,7 @@ int main(int argc, char *argv[])
|
|||
//QObject::connect(&app, &QApplication::aboutToQuit, &w, &QMainWindow::close);
|
||||
QObject::connect(squawk, &Core::Squawk::quit, squawk, &Core::Squawk::deleteLater);
|
||||
QObject::connect(squawk, &Core::Squawk::destroyed, coreThread, &QThread::quit, Qt::QueuedConnection);
|
||||
QObject::connect(coreThread, &QThread::finished, &app, &QApplication::quit, Qt::QueuedConnection);
|
||||
QObject::connect(coreThread, &QThread::finished, &app, &Root::quit, Qt::QueuedConnection);
|
||||
|
||||
coreThread->start();
|
||||
int result = app.exec();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue