Issue #2112 - Part 5: Remove Servo from forwarding code used by magic pointer classes

This commit is contained in:
FranklinDM 2024-03-25 02:02:08 +08:00 committed by roytam1
commit a93a7bed47
52 changed files with 274 additions and 1116 deletions

View file

@ -296,10 +296,7 @@ KeyframeEffectReadOnly::UpdateProperties(nsStyleContext* aStyleContext)
runningOnCompositorProperties.HasProperty(property.mProperty);
}
// FIXME (bug 1303235): Do this for Servo too
if (aStyleContext->PresContext()->StyleSet()->IsGecko()) {
CalculateCumulativeChangeHint(aStyleContext);
}
CalculateCumulativeChangeHint(aStyleContext);
MarkCascadeNeedsUpdate();
@ -1286,8 +1283,6 @@ CreateStyleContextForAnimationValue(nsCSSPropertyID aProperty,
nsCOMArray<nsIStyleRule> rules;
rules.AppendObject(styleRule);
MOZ_ASSERT(aBaseStyleContext->PresContext()->StyleSet()->IsGecko(),
"ServoStyleSet should not use StyleAnimationValue for animations");
nsStyleSet* styleSet =
aBaseStyleContext->PresContext()->StyleSet()->AsGecko();
@ -1362,10 +1357,8 @@ KeyframeEffectReadOnly::CanIgnoreIfNotVisible() const
return false;
}
// FIXME (bug 1303235): We don't calculate mCumulativeChangeHint for
// the Servo backend yet
nsPresContext* presContext = GetPresContext();
if (!presContext || presContext->StyleSet()->IsServo()) {
if (!presContext) {
return false;
}