qmlfrontend/main.cpp
author unC0Rr
Tue, 06 Nov 2018 17:00:35 +0100
changeset 14164 745c73e0e644
parent 12854 28cb18c5e712
child 14175 8354b390f1a2
permissions -rw-r--r--
Start working on frontend to rust engine rewrite
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
12854
28cb18c5e712 Add new qmlfrontend project template
unc0rr
parents:
diff changeset
     1
#include <QGuiApplication>
28cb18c5e712 Add new qmlfrontend project template
unc0rr
parents:
diff changeset
     2
#include <QQmlApplicationEngine>
28cb18c5e712 Add new qmlfrontend project template
unc0rr
parents:
diff changeset
     3
14164
745c73e0e644 Start working on frontend to rust engine rewrite
unC0Rr
parents: 12854
diff changeset
     4
#include "hwengine.h"
745c73e0e644 Start working on frontend to rust engine rewrite
unC0Rr
parents: 12854
diff changeset
     5
745c73e0e644 Start working on frontend to rust engine rewrite
unC0Rr
parents: 12854
diff changeset
     6
int main(int argc, char* argv[]) {
12854
28cb18c5e712 Add new qmlfrontend project template
unc0rr
parents:
diff changeset
     7
  QCoreApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
28cb18c5e712 Add new qmlfrontend project template
unc0rr
parents:
diff changeset
     8
  QGuiApplication app(argc, argv);
28cb18c5e712 Add new qmlfrontend project template
unc0rr
parents:
diff changeset
     9
28cb18c5e712 Add new qmlfrontend project template
unc0rr
parents:
diff changeset
    10
  QQmlApplicationEngine engine;
14164
745c73e0e644 Start working on frontend to rust engine rewrite
unC0Rr
parents: 12854
diff changeset
    11
745c73e0e644 Start working on frontend to rust engine rewrite
unC0Rr
parents: 12854
diff changeset
    12
  HWEngine::exposeToQML();
745c73e0e644 Start working on frontend to rust engine rewrite
unC0Rr
parents: 12854
diff changeset
    13
12854
28cb18c5e712 Add new qmlfrontend project template
unc0rr
parents:
diff changeset
    14
  engine.load(QUrl(QLatin1String("qrc:/main.qml")));
14164
745c73e0e644 Start working on frontend to rust engine rewrite
unC0Rr
parents: 12854
diff changeset
    15
  if (engine.rootObjects().isEmpty()) return -1;
12854
28cb18c5e712 Add new qmlfrontend project template
unc0rr
parents:
diff changeset
    16
28cb18c5e712 Add new qmlfrontend project template
unc0rr
parents:
diff changeset
    17
  return app.exec();
28cb18c5e712 Add new qmlfrontend project template
unc0rr
parents:
diff changeset
    18
}