2022-08-19 15:59:36 +02:00
|
|
|
// Copyright (C) 2021 The Qt Company Ltd.
|
|
|
|
|
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause
|
2021-09-23 09:21:13 +02:00
|
|
|
|
2015-11-09 17:09:42 +01:00
|
|
|
#include <QGuiApplication>
|
|
|
|
|
#include <QQmlApplicationEngine>
|
|
|
|
|
|
2021-09-23 09:21:13 +02:00
|
|
|
|
2015-11-09 17:09:42 +01:00
|
|
|
int main(int argc, char *argv[])
|
|
|
|
|
{
|
|
|
|
|
QGuiApplication app(argc, argv);
|
|
|
|
|
|
|
|
|
|
QQmlApplicationEngine engine;
|
2021-10-21 16:36:09 +02:00
|
|
|
const QUrl url(u"qrc:/transitions/main.qml"_qs);
|
2020-04-08 10:39:24 +02:00
|
|
|
QObject::connect(&engine, &QQmlApplicationEngine::objectCreated,
|
2020-08-12 16:59:04 +02:00
|
|
|
&app, [url](QObject *obj, const QUrl &objUrl) {
|
|
|
|
|
if (!obj && url == objUrl)
|
|
|
|
|
QCoreApplication::exit(-1);
|
|
|
|
|
}, Qt::QueuedConnection);
|
2020-04-08 10:39:24 +02:00
|
|
|
engine.load(url);
|
2015-11-09 17:09:42 +01:00
|
|
|
|
|
|
|
|
return app.exec();
|
|
|
|
|
}
|