-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain2.cpp
More file actions
34 lines (24 loc) · 840 Bytes
/
Copy pathmain2.cpp
File metadata and controls
34 lines (24 loc) · 840 Bytes
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
#include <QDebug>
#include <QtCore/QCoreApplication>
#include <QtWebEngineQuick/qtwebenginequickglobal.h>
#include <QtQml/QQmlApplicationEngine>
#include <QtGui/QGuiApplication>
#include <QFile>
int main(int argc, char **argv){
qDebug()<<"hello world";
QCoreApplication::setApplicationName("QMemos");
QtWebEngineQuick::initialize();
QGuiApplication app(argc, argv);
QQmlApplicationEngine appEngine;
QObject::connect(
&appEngine,
&QQmlApplicationEngine::objectCreationFailed,
&app,
[]() { QCoreApplication::exit(-1); },
Qt::QueuedConnection);
//appEngine.load(QUrl("qrc:/MemosPage.qml"));
appEngine.loadFromModule("untitled6","MemosPage");
// if (appEngine.rootObjects().isEmpty())
// qFatal("Failed to load sources");
return app.exec();
}