Bug 1474213 - Add another assertion in DocumentTimeline::NotifyAnimationUpdated checking the animation's timeline is the DocumentTimeline. r?birtles
MozReview-Commit-ID: 1J68IdoH3sy
--- a/dom/animation/DocumentTimeline.cpp
+++ b/dom/animation/DocumentTimeline.cpp
@@ -128,16 +128,19 @@ DocumentTimeline::ToTimelineTime(const T
- timing->GetNavigationStartTimeStamp()
- mOriginTime);
return result;
}
void
DocumentTimeline::NotifyAnimationUpdated(Animation& aAnimation)
{
+ MOZ_ASSERT(aAnimation.GetTimeline() == this,
+ "Should be used for animations that the animation's timeline "
+ "is this DocumentTimeline");
MOZ_ASSERT(aAnimation.GetTimelineDocument() &&
aAnimation.GetTimelineDocument() == mDocument,
"Should be used for animations that the animation's timeline "
"document is the same document of this DocumentTimeline");
AnimationTimeline::NotifyAnimationUpdated(aAnimation);
if (!mIsObservingRefreshDriver) {