зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1311257 - Support missing keyframes handling for stylo. r=birtles
MozReview-Commit-ID: 1Iz6By2Y2Gp --HG-- extra : rebase_source : 94dd3845c271e89f88dc7351b4cea179bd3bb2e5
This commit is contained in:
Родитель
e432173483
Коммит
79052959a8
|
@ -439,11 +439,7 @@ KeyframeEffectReadOnly::CompositeValue(
|
|||
CompositeOperation aCompositeOperation)
|
||||
{
|
||||
MOZ_ASSERT(mTarget, "CompositeValue should be called with target element");
|
||||
|
||||
// FIXME: Bug 1311257: Get the base value for the servo backend.
|
||||
if (mDocument->IsStyledByServo()) {
|
||||
return aValueToComposite;
|
||||
}
|
||||
MOZ_ASSERT(!mDocument->IsStyledByServo());
|
||||
|
||||
StyleAnimationValue underlyingValue =
|
||||
GetUnderlyingStyle(aProperty, aAnimationRule);
|
||||
|
@ -672,13 +668,6 @@ KeyframeEffectReadOnly::ComposeStyleRule(
|
|||
// Bug 1329878 - Stylo: Implement accumulate and addition on Servo
|
||||
// AnimationValue.
|
||||
|
||||
// For unsupported or non-animatable animation types, we get nullptrs.
|
||||
if (!aSegment.mFromValue.mServo|| !aSegment.mToValue.mServo) {
|
||||
NS_ERROR("Compose style for unsupported or non-animatable property, "
|
||||
"so get invalid RawServoAnimationValues");
|
||||
return;
|
||||
}
|
||||
|
||||
Servo_AnimationCompose(&aAnimationValues,
|
||||
&mBaseStyleValuesForServo,
|
||||
aProperty.mProperty,
|
||||
|
|
|
@ -469,9 +469,7 @@ KeyframeUtils::GetKeyframesFromObject(JSContext* aCx,
|
|||
return keyframes;
|
||||
}
|
||||
|
||||
// FIXME: Bug 1311257: Support missing keyframes for Servo backend.
|
||||
if ((!AnimationUtils::IsCoreAPIEnabled() ||
|
||||
aDocument->IsStyledByServo()) &&
|
||||
if (!AnimationUtils::IsCoreAPIEnabled() &&
|
||||
RequiresAdditiveAnimation(keyframes, aDocument)) {
|
||||
keyframes.Clear();
|
||||
aRv.Throw(NS_ERROR_DOM_ANIM_MISSING_PROPS_ERR);
|
||||
|
@ -1444,8 +1442,6 @@ GetKeyframeListFromPropertyIndexedKeyframe(JSContext* aCx,
|
|||
return;
|
||||
}
|
||||
|
||||
bool isServoBackend = aDocument->IsStyledByServo();
|
||||
|
||||
// Create a set of keyframes for each property.
|
||||
nsCSSParser parser(aDocument->CSSLoader());
|
||||
nsClassHashtable<nsFloatHashKey, Keyframe> processedKeyframes;
|
||||
|
@ -1458,9 +1454,8 @@ GetKeyframeListFromPropertyIndexedKeyframe(JSContext* aCx,
|
|||
|
||||
// If we only have one value, we should animate from the underlying value
|
||||
// using additive animation--however, we don't support additive animation
|
||||
// for Servo backend (bug 1311257) or when the core animation API pref is
|
||||
// switched off.
|
||||
if ((!AnimationUtils::IsCoreAPIEnabled() || isServoBackend) &&
|
||||
// when the core animation API pref is switched off.
|
||||
if ((!AnimationUtils::IsCoreAPIEnabled()) &&
|
||||
count == 1) {
|
||||
aRv.Throw(NS_ERROR_DOM_ANIM_MISSING_PROPS_ERR);
|
||||
return;
|
||||
|
|
Загрузка…
Ссылка в новой задаче