summaryrefslogtreecommitdiffstats
path: root/examples/sensors/grue/main.cpp
diff options
context:
space:
mode:
authorTamas Martinec <tamas.martinec@symbio.com>2021-06-10 13:14:04 +0300
committerAlexandru Croitor <alexandru.croitor@qt.io>2021-08-18 15:15:02 +0200
commita063b9f61ddea7403d36a5288ff6f8dc0d95ddfb (patch)
treef8b116d977bf3774c5c9c743a253106879f67a19 /examples/sensors/grue/main.cpp
parent63fe6819c79c835adf652f8dd99fda54f6d35cdc (diff)
QtSensors: Fix and simplify the Grue example
Refactoring to use QML cpp class registration instead of a QML plugin. Pick-to: 6.2 Task-number: QTBUG-92514 Change-Id: I7637232d27575522e83ebdbc5c60cdb5663d2cd0 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Diffstat (limited to 'examples/sensors/grue/main.cpp')
-rw-r--r--examples/sensors/grue/main.cpp13
1 files changed, 11 insertions, 2 deletions
diff --git a/examples/sensors/grue/main.cpp b/examples/sensors/grue/main.cpp
index 499a3432..c80e7ef2 100644
--- a/examples/sensors/grue/main.cpp
+++ b/examples/sensors/grue/main.cpp
@@ -48,5 +48,14 @@
**
****************************************************************************/
-#include "../stub.h"
-SENSORS_EXAMPLE_MAIN(grue)
+#include <QGuiApplication>
+#include <QQuickView>
+
+int main(int argc, char **argv)
+{
+ QGuiApplication app(argc,argv);
+ QQuickView view;
+ view.setSource(QUrl("qrc:/QMLGrueSensor/grue.qml"));
+ view.show();
+ return app.exec();
+}