-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.cpp
24 lines (18 loc) · 709 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
#include <QGuiApplication>
#include <QQmlApplicationEngine>
#include "Counter.h"
int main(int argc, char *argv[])
{
QCoreApplication::setAttribute(Qt::AA_EnableHighDpiScaling, true);
QCoreApplication::setAttribute(Qt::AA_UseHighDpiPixmaps, true);
QGuiApplication app(argc, argv);
QGuiApplication::setApplicationName("Counter");
QGuiApplication::setApplicationVersion("2.9.4");
QGuiApplication::setOrganizationName("Enclave Software");
qmlRegisterType<Counter>("com.enclave.counter", 1, 4, "Counter");
QQmlApplicationEngine engine;
engine.load(QUrl(QStringLiteral("qrc:/main.qml")));
if (engine.rootObjects().isEmpty())
return -1;
return app.exec();
}