Use new connection syntax and return -1 on load failures, which
avoids hanging processes and empty windows in case some module is not
installed.
Change-Id: I4966c9657b752eee8612fa893a0489bc8a64ccfc
Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com>
f.setVersion(4, 4);\
view.setFormat(f);\
}\
- view.connect(view.engine(), SIGNAL(quit()), &app, SLOT(quit()));\
+ view.connect(view.engine(), &QQmlEngine::quit, &app, &QCoreApplication::quit);\
new QQmlFileSelector(view.engine(), &view);\
view.setSource(QUrl("qrc:///" #NAME ".qml")); \
+ if (view.status() == QQuickView::Error)\
+ return -1;\
view.setResizeMode(QQuickView::SizeRootObjectToView);\
if (QGuiApplication::platformName() == QLatin1String("qnx") || \
QGuiApplication::platformName() == QLatin1String("eglfs")) {\