aboutsummaryrefslogtreecommitdiffstats
path: root/src/quick/util
diff options
context:
space:
mode:
authorUlf Hermann <ulf.hermann@qt.io>2020-04-29 10:32:26 +0200
committerUlf Hermann <ulf.hermann@qt.io>2020-05-19 08:36:04 +0200
commit19ea4e630c70cdab1f7eec4f1a8f278df8915720 (patch)
treecb5ad929688d5eb5becd74964862db6127b857af /src/quick/util
parentd29f3d7a62780d74f62330b0e3a0703a72155852 (diff)
Clean up registration of QEasingCurve
We don't need to register the Type enum for both QtQml and QtQuick. QtQml is enough. Removing this makes the whole manual value type registration obsolete. Furthermore, we want QEasingCurve as QML_FOREIGN as we have several classes with properties of that type. To keep it nice and tidy, we make the uppercase-named enum holder class a separate type. Unfortunately, the Type enums differ in one entry: QEasingCurve::BezierSpline is called Easing.Bezier in QML. Therefore, we need to keep the custom enum around. We can change all users in qtdeclarative to use the name from QEasingCurve, though. Change-Id: Ibbc78d8bbf8938e2a8722f8c09833a0c73394c3d Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Diffstat (limited to 'src/quick/util')
-rw-r--r--src/quick/util/qquickanimation.cpp4
-rw-r--r--src/quick/util/qquickvaluetypes.cpp7
-rw-r--r--src/quick/util/qquickvaluetypes_p.h6
3 files changed, 2 insertions, 15 deletions
diff --git a/src/quick/util/qquickanimation.cpp b/src/quick/util/qquickanimation.cpp
index e5e25d141b..a65065564b 100644
--- a/src/quick/util/qquickanimation.cpp
+++ b/src/quick/util/qquickanimation.cpp
@@ -2393,7 +2393,7 @@ void QQuickPropertyAnimation::setTo(const QVariant &t)
\li Easing curve for a bounce (exponentially decaying parabolic bounce) function easing out/in: deceleration until halfway, then acceleration.
\li \inlineimage qeasingcurve-outinbounce.png
\row
- \li \c Easing.Bezier
+ \li \c Easing.BezierSpline
\li Custom easing curve defined by the easing.bezierCurve property.
\li
\endtable
@@ -2408,7 +2408,7 @@ void QQuickPropertyAnimation::setTo(const QVariant &t)
\c easing.period is only applicable if easing.type is: \c Easing.InElastic, \c Easing.OutElastic,
\c Easing.InOutElastic or \c Easing.OutInElastic.
- \c easing.bezierCurve is only applicable if easing.type is: \c Easing.Bezier. This property is a list<real> containing
+ \c easing.bezierCurve is only applicable if easing.type is: \c Easing.BezierSpline. This property is a list<real> containing
groups of three points defining a curve from 0,0 to 1,1 - control1, control2,
end point: [cx1, cy1, cx2, cy2, endx, endy, ...]. The last point must be 1,1.
diff --git a/src/quick/util/qquickvaluetypes.cpp b/src/quick/util/qquickvaluetypes.cpp
index d836946214..8fc108de8c 100644
--- a/src/quick/util/qquickvaluetypes.cpp
+++ b/src/quick/util/qquickvaluetypes.cpp
@@ -46,13 +46,6 @@
QT_BEGIN_NAMESPACE
-namespace QQuickValueTypes {
- void registerValueTypes()
- {
- QQmlValueTypeFactory::registerValueTypes("QtQuick", 2, 0);
- }
-}
-
QString QQuickColorValueType::toString() const
{
return v.name(v.alpha() != 255 ? QColor::HexArgb : QColor::HexRgb);
diff --git a/src/quick/util/qquickvaluetypes_p.h b/src/quick/util/qquickvaluetypes_p.h
index a94f4ac6a7..8859e12322 100644
--- a/src/quick/util/qquickvaluetypes_p.h
+++ b/src/quick/util/qquickvaluetypes_p.h
@@ -66,12 +66,6 @@
QT_BEGIN_NAMESPACE
-namespace QQuickValueTypes {
-
-void registerValueTypes();
-
-}
-
class QQuickColorValueType
{
QColor v;