Bug 1432104 - KeyframeUtils::GetAnimationPropertiesFromKeyframes needs specializations both for GeckoStyleContext* and const ServoStyleContext*. r?birtles
The implementation of the template function is defined in KeyframeUtils.cpp,
whereas the caller is inside KeyframeEffectReadOnly.cpp. I guess it's been
compiled accidentally because of unified builds.
MozReview-Commit-ID: 9GeIT7nDpLG
--- a/dom/animation/KeyframeUtils.cpp
+++ b/dom/animation/KeyframeUtils.cpp
@@ -1673,9 +1673,25 @@ DistributeRange(const Range<Keyframe>& a
const double startOffset = aRange[0].mComputedOffset;
const double diffOffset = aRange[n].mComputedOffset - startOffset;
for (auto iter = rangeToAdjust.begin(); iter != rangeToAdjust.end(); ++iter) {
size_t index = iter - aRange.begin();
iter->mComputedOffset = startOffset + double(index) / n * diffOffset;
}
}
+template
+nsTArray<AnimationProperty>
+KeyframeUtils::GetAnimationPropertiesFromKeyframes(
+ const nsTArray<Keyframe>& aKeyframes,
+ dom::Element* aElement,
+ GeckoStyleContext* aStyle,
+ dom::CompositeOperation aEffectComposite);
+
+template
+nsTArray<AnimationProperty>
+KeyframeUtils::GetAnimationPropertiesFromKeyframes(
+ const nsTArray<Keyframe>& aKeyframes,
+ dom::Element* aElement,
+ const ServoStyleContext* aStyle,
+ dom::CompositeOperation aEffectComposite);
+
} // namespace mozilla