aboutsummaryrefslogtreecommitdiffstats
path: root/src/imports/labsanimation
diff options
context:
space:
mode:
Diffstat (limited to 'src/imports/labsanimation')
-rw-r--r--src/imports/labsanimation/CMakeLists.txt4
-rw-r--r--src/imports/labsanimation/labsanimation.pro2
-rw-r--r--src/imports/labsanimation/plugin.cpp8
-rw-r--r--src/imports/labsanimation/qquickboundaryrule_p.h1
4 files changed, 11 insertions, 4 deletions
diff --git a/src/imports/labsanimation/CMakeLists.txt b/src/imports/labsanimation/CMakeLists.txt
index a8830231da..a4de38267e 100644
--- a/src/imports/labsanimation/CMakeLists.txt
+++ b/src/imports/labsanimation/CMakeLists.txt
@@ -6,7 +6,7 @@
qt_add_qml_module(labsanimationplugin
URI "Qt.labs.animation"
- VERSION "1.0"
+ VERSION "${CMAKE_PROJECT_VERSION}"
CLASSNAME QtLabsAnimationPlugin
SKIP_TYPE_REGISTRATION
GENERATE_QMLTYPES
@@ -20,5 +20,5 @@ qt_add_qml_module(labsanimationplugin
#### Keys ignored in scope 1:.:.:labsanimation.pro:<TRUE>:
# CXX_MODULE = "qml"
-# IMPORT_VERSION = "1.0"
+# QML_IMPORT_VERSION = "$$QT_VERSION"
# TARGETPATH = "Qt/labs/animation"
diff --git a/src/imports/labsanimation/labsanimation.pro b/src/imports/labsanimation/labsanimation.pro
index f64ae775c6..5fd8ff25a7 100644
--- a/src/imports/labsanimation/labsanimation.pro
+++ b/src/imports/labsanimation/labsanimation.pro
@@ -1,7 +1,7 @@
CXX_MODULE = qml
TARGET = labsanimationplugin
TARGETPATH = Qt/labs/animation
-IMPORT_VERSION = 1.0
+QML_IMPORT_VERSION = $$QT_VERSION
SOURCES += \
qquickboundaryrule.cpp \
diff --git a/src/imports/labsanimation/plugin.cpp b/src/imports/labsanimation/plugin.cpp
index bd732a6aba..9c985f0dcf 100644
--- a/src/imports/labsanimation/plugin.cpp
+++ b/src/imports/labsanimation/plugin.cpp
@@ -42,6 +42,8 @@
#include "qquickboundaryrule_p.h"
+extern void qml_register_types_Qt_labs_animation();
+
QT_BEGIN_NAMESPACE
/*!
@@ -66,7 +68,11 @@ class QtLabsAnimationPlugin : public QQmlEngineExtensionPlugin
Q_OBJECT
Q_PLUGIN_METADATA(IID QQmlEngineExtensionInterface_iid)
public:
- QtLabsAnimationPlugin(QObject *parent = nullptr) : QQmlEngineExtensionPlugin(parent) { }
+ QtLabsAnimationPlugin(QObject *parent = nullptr) : QQmlEngineExtensionPlugin(parent)
+ {
+ volatile auto registration = &qml_register_types_Qt_labs_animation;
+ Q_UNUSED(registration);
+ }
};
//![class decl]
diff --git a/src/imports/labsanimation/qquickboundaryrule_p.h b/src/imports/labsanimation/qquickboundaryrule_p.h
index 1681558304..33cf0bb094 100644
--- a/src/imports/labsanimation/qquickboundaryrule_p.h
+++ b/src/imports/labsanimation/qquickboundaryrule_p.h
@@ -78,6 +78,7 @@ class QQuickBoundaryRule : public QObject, public QQmlPropertyValueInterceptor
Q_PROPERTY(QEasingCurve easing READ easing WRITE setEasing NOTIFY easingChanged)
Q_PROPERTY(int returnDuration READ returnDuration WRITE setReturnDuration NOTIFY returnDurationChanged)
QML_NAMED_ELEMENT(BoundaryRule)
+ QML_ADDED_IN_VERSION(1, 0)
public:
enum OvershootFilter {