Issue #2488 - Part 6: Define and declare CSSStyleSheet cast functions directly in StyleSheet

This renames AsGecko calls to AsConcrete and removes the header containing leftover Stylo macros.
This commit is contained in:
FranklinDM 2024-03-29 16:30:12 +08:00 committed by roytam1
commit f0116f51db
18 changed files with 109 additions and 134 deletions

View file

@ -321,7 +321,7 @@ nsStyleLinkElement::DoUpdateStyleSheet(nsIDocument* aOldDocument,
Element* oldScopeElement = nullptr;
if (mStyleSheet) {
oldScopeElement = mStyleSheet->AsGecko()->GetScopeElement();
oldScopeElement = mStyleSheet->AsConcrete()->GetScopeElement();
}
if (mStyleSheet && (aOldDocument || aOldShadowRoot)) {
@ -483,7 +483,7 @@ nsStyleLinkElement::UpdateStyleSheetScopedness(bool aIsNowScoped)
return;
}
CSSStyleSheet* sheet = mStyleSheet->AsGecko();
CSSStyleSheet* sheet = mStyleSheet->AsConcrete();
nsCOMPtr<nsIContent> thisContent;
CallQueryInterface(this, getter_AddRefs(thisContent));