summaryrefslogtreecommitdiffstats
path: root/examples/graphs/3d
diff options
context:
space:
mode:
Diffstat (limited to 'examples/graphs/3d')
-rw-r--r--examples/graphs/3d/axishandling/axishandling.pro4
-rw-r--r--examples/graphs/3d/axishandling/main.cpp9
-rw-r--r--examples/graphs/3d/surfacegallery/main.cpp8
-rw-r--r--examples/graphs/3d/surfacegallery/qml/surfacegallery/SurfaceOscilloscope.qml2
-rw-r--r--examples/graphs/3d/surfacegallery/surfacegallery.pro4
5 files changed, 7 insertions, 20 deletions
diff --git a/examples/graphs/3d/axishandling/axishandling.pro b/examples/graphs/3d/axishandling/axishandling.pro
index 55e20f78..f4d1f62c 100644
--- a/examples/graphs/3d/axishandling/axishandling.pro
+++ b/examples/graphs/3d/axishandling/axishandling.pro
@@ -2,7 +2,9 @@
error( "Couldn't find the examples.pri file!" )
}
-DEFINES += QMAKE_BUILD
+CONFIG += qmltypes
+QML_IMPORT_NAME = AxisHandlingExample
+QML_IMPORT_MAJOR_VERSION = 1
SOURCES += main.cpp \
customformatter.cpp
diff --git a/examples/graphs/3d/axishandling/main.cpp b/examples/graphs/3d/axishandling/main.cpp
index 19ac8869..9cf4026d 100644
--- a/examples/graphs/3d/axishandling/main.cpp
+++ b/examples/graphs/3d/axishandling/main.cpp
@@ -6,19 +6,10 @@
#include <QtQml>
#include <QtQuick/qquickview.h>
-#ifdef QMAKE_BUILD
-#include "customformatter.h"
-Q_DECLARE_METATYPE(CustomFormatter *)
-#endif
-
int main(int argc, char *argv[])
{
QGuiApplication app(argc, argv);
-#ifdef QMAKE_BUILD
- qmlRegisterType<CustomFormatter>("AxisHandling", 1, 0, "CustomFormatter");
-#endif
-
QQuickView viewer;
// The following are needed to make examples run without having to install the
diff --git a/examples/graphs/3d/surfacegallery/main.cpp b/examples/graphs/3d/surfacegallery/main.cpp
index 396c0628..30fff3af 100644
--- a/examples/graphs/3d/surfacegallery/main.cpp
+++ b/examples/graphs/3d/surfacegallery/main.cpp
@@ -9,18 +9,10 @@
#include <QtQml/qqmlengine.h>
#include <QtQuick/qquickview.h>
-#ifdef QMAKE_BUILD
-#include "datasource.h"
-#endif
-
int main(int argc, char *argv[])
{
QGuiApplication app(argc, argv);
-#ifdef QMAKE_BUILD
- qmlRegisterType<DataSource>("SurfaceGallery", 1, 0, "DataSource");
-#endif
-
QQuickView viewer;
//! [1]
diff --git a/examples/graphs/3d/surfacegallery/qml/surfacegallery/SurfaceOscilloscope.qml b/examples/graphs/3d/surfacegallery/qml/surfacegallery/SurfaceOscilloscope.qml
index 3570253d..59de7372 100644
--- a/examples/graphs/3d/surfacegallery/qml/surfacegallery/SurfaceOscilloscope.qml
+++ b/examples/graphs/3d/surfacegallery/qml/surfacegallery/SurfaceOscilloscope.qml
@@ -5,7 +5,7 @@ import QtQuick
import QtQuick.Controls.Basic
import QtGraphs
//! [0]
-import SurfaceGalleryExample
+import SurfaceGallery
//! [0]
Item {
diff --git a/examples/graphs/3d/surfacegallery/surfacegallery.pro b/examples/graphs/3d/surfacegallery/surfacegallery.pro
index 0da2a48a..620bb52e 100644
--- a/examples/graphs/3d/surfacegallery/surfacegallery.pro
+++ b/examples/graphs/3d/surfacegallery/surfacegallery.pro
@@ -2,7 +2,9 @@
error( "Couldn't find the examples.pri file!" )
}
-DEFINES += QMAKE_BUILD
+CONFIG += qmltypes
+QML_IMPORT_NAME = SurfaceGallery
+QML_IMPORT_MAJOR_VERSION = 1
QT += graphs