8int main(
int argc,
char *argv[])
10 QApplication app(argc, argv);
17 QQmlApplicationEngine engine;
18 engine.addImportPath(QDir::cleanPath(QCoreApplication::applicationDirPath() + QDir::separator() +
19 PLUGINS_RELATIVE_PATH));
21 engine.addImportPath(QDir::cleanPath(QCoreApplication::applicationDirPath() + QDir::separator() +
22 ".." + QDir::separator() +
23 PLUGINS_RELATIVE_PATH + QDir::separator() +
27 engine.load(QUrl(QStringLiteral(
"qrc:/main.qml")));
29 QObject *topLevel = engine.rootObjects().value(0);
30 QQuickWindow *window = qobject_cast<QQuickWindow *>(topLevel);
34 for(
int i=0;i<argc;i++){
35 params.append(argv[i]);
38 QMetaObject::invokeMethod(topLevel,
"parseParameters",
40 Q_RETURN_ARG(QVariant, retVal),
41 Q_ARG(QVariant,params));
50 return (app.exec()!=0?1:0);