diff options
author | Ulf Hermann <ulf.hermann@qt.io> | 2019-11-25 14:49:07 +0100 |
---|---|---|
committer | Ulf Hermann <ulf.hermann@qt.io> | 2020-01-15 14:09:19 +0100 |
commit | 5a4ffa0de0ecc666a514ef60f0149a76d25b040d (patch) | |
tree | 5f9671c1c85b52bfdd051598e2c524ead98b0160 /src/quick/util/qquickanimation_p_p.h | |
parent | d9a02d5c834b57f0da781c7dcf8d74e3b4ce1314 (diff) |
QQmlListProperty: Add replace and removeLast functions
This allows us to implement QmlListWrapper::virtualPut(). Also, the
additional functions make the list properties useful in other contexts.
Fixes: QTBUG-79263
Change-Id: I528bc69222ca7743f0fc3697c3aed2a3468b4d87
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Diffstat (limited to 'src/quick/util/qquickanimation_p_p.h')
-rw-r--r-- | src/quick/util/qquickanimation_p_p.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/quick/util/qquickanimation_p_p.h b/src/quick/util/qquickanimation_p_p.h index c20ec65c24..8d23242b68 100644 --- a/src/quick/util/qquickanimation_p_p.h +++ b/src/quick/util/qquickanimation_p_p.h @@ -256,7 +256,12 @@ public: : QQuickAbstractAnimationPrivate() {} static void append_animation(QQmlListProperty<QQuickAbstractAnimation> *list, QQuickAbstractAnimation *role); + static QQuickAbstractAnimation *at_animation(QQmlListProperty<QQuickAbstractAnimation> *list, int index); + static int count_animation(QQmlListProperty<QQuickAbstractAnimation> *list); static void clear_animation(QQmlListProperty<QQuickAbstractAnimation> *list); + static void replace_animation(QQmlListProperty<QQuickAbstractAnimation> *list, int index, + QQuickAbstractAnimation *role); + static void removeLast_animation(QQmlListProperty<QQuickAbstractAnimation> *list); QList<QQuickAbstractAnimation *> animations; }; |