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
committerQt Cherry-pick Bot <cherrypick_bot@qt-project.org>2021-08-18 16:11:44 +0000
commit55c42b090119078051371324f590c9e741e9d165 (patch)
tree9ea9920925dd203026d820f621cccdc92b4bd636 /examples/sensors/grue/main.cpp
parent261af4a20cb06aac4215b2d8348c54ac8a34c007 (diff)
QtSensors: Fix and simplify the Grue example
Refactoring to use QML cpp class registration instead of a QML plugin. 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> (cherry picked from commit a063b9f61ddea7403d36a5288ff6f8dc0d95ddfb) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
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();
+}