summaryrefslogtreecommitdiffstats
path: root/src/declarative/util
diff options
context:
space:
mode:
authorMichael Brasser <michael.brasser@nokia.com>2010-02-26 03:46:05 (GMT)
committerMichael Brasser <michael.brasser@nokia.com>2010-02-26 03:46:35 (GMT)
commit46340f1c5f8765276701a2831d6efd45607d8ff5 (patch)
tree1cfa4180465b175885f21b884ddbc2cab04fc00d /src/declarative/util
parent8a3eef027ffaeb69eeee89b7868c17c1f246edc8 (diff)
downloadQt-46340f1c5f8765276701a2831d6efd45607d8ff5.zip
Qt-46340f1c5f8765276701a2831d6efd45607d8ff5.tar.gz
Qt-46340f1c5f8765276701a2831d6efd45607d8ff5.tar.bz2
Fix ParentAnimation crash.
Diffstat (limited to 'src/declarative/util')
-rw-r--r--src/declarative/util/qdeclarativeanimation.cpp9
-rw-r--r--src/declarative/util/qdeclarativeanimation_p.h3
2 files changed, 9 insertions, 3 deletions
diff --git a/src/declarative/util/qdeclarativeanimation.cpp b/src/declarative/util/qdeclarativeanimation.cpp
index 6dc91de..328f0e4 100644
--- a/src/declarative/util/qdeclarativeanimation.cpp
+++ b/src/declarative/util/qdeclarativeanimation.cpp
@@ -1509,6 +1509,11 @@ QDeclarativeAnimationGroup::QDeclarativeAnimationGroup(QObject *parent)
{
}
+QDeclarativeAnimationGroup::QDeclarativeAnimationGroup(QDeclarativeAnimationGroupPrivate &dd, QObject *parent)
+ : QDeclarativeAbstractAnimation(dd, parent)
+{
+}
+
void QDeclarativeAnimationGroupPrivate::append_animation(QDeclarativeListProperty<QDeclarativeAbstractAnimation> *list, QDeclarativeAbstractAnimation *a)
{
QDeclarativeAnimationGroup *q = qobject_cast<QDeclarativeAnimationGroup *>(list->object);
@@ -2366,10 +2371,8 @@ void QDeclarativePropertyAnimation::transition(QDeclarativeStateActions &actions
}
}
-
-
QDeclarativeParentAnimation::QDeclarativeParentAnimation(QObject *parent)
- : QDeclarativeAnimationGroup(parent)
+ : QDeclarativeAnimationGroup(*(new QDeclarativeParentAnimationPrivate), parent)
{
Q_D(QDeclarativeParentAnimation);
d->topLevelGroup = new QSequentialAnimationGroup;
diff --git a/src/declarative/util/qdeclarativeanimation_p.h b/src/declarative/util/qdeclarativeanimation_p.h
index b57bd9e..0f23f5c 100644
--- a/src/declarative/util/qdeclarativeanimation_p.h
+++ b/src/declarative/util/qdeclarativeanimation_p.h
@@ -413,6 +413,9 @@ public:
QDeclarativeListProperty<QDeclarativeAbstractAnimation> animations();
friend class QDeclarativeAbstractAnimation;
+
+protected:
+ QDeclarativeAnimationGroup(QDeclarativeAnimationGroupPrivate &dd, QObject *parent);
};
class QDeclarativeSequentialAnimation : public QDeclarativeAnimationGroup