mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 938334 - Use PseudoElementSupportsStyleAttribute(Type) when it makes sense to do so and remove now unnecessary nsCSSPseudoElements functions. r=dbaron
This commit is contained in:
parent
04546e289c
commit
89b6530bc5
@ -2386,8 +2386,8 @@ ElementRestyler::RestyleSelf(nsIFrame* aSelf, nsRestyleHint aRestyleHint)
|
||||
nsCSSPseudoElements::ePseudo_PseudoElementCount,
|
||||
"Unexpected pseudo type");
|
||||
Element* pseudoElement =
|
||||
nsCSSPseudoElements::PseudoElementSupportsStyleAttribute(pseudoTag) ||
|
||||
nsCSSPseudoElements::PseudoElementSupportsUserActionState(pseudoTag) ?
|
||||
nsCSSPseudoElements::PseudoElementSupportsStyleAttribute(pseudoType) ||
|
||||
nsCSSPseudoElements::PseudoElementSupportsUserActionState(pseudoType) ?
|
||||
aSelf->GetContent()->AsElement() : nullptr;
|
||||
MOZ_ASSERT(element != pseudoElement);
|
||||
newContext = styleSet->ResolvePseudoElementStyle(element,
|
||||
|
@ -78,19 +78,11 @@ public:
|
||||
return PseudoElementHasFlags(aType, CSS_PSEUDO_ELEMENT_CONTAINS_ELEMENTS);
|
||||
}
|
||||
|
||||
static bool PseudoElementSupportsStyleAttribute(nsIAtom *aAtom) {
|
||||
return PseudoElementHasFlags(GetPseudoType(aAtom), CSS_PSEUDO_ELEMENT_SUPPORTS_STYLE_ATTRIBUTE);
|
||||
}
|
||||
|
||||
static bool PseudoElementSupportsStyleAttribute(const Type aType) {
|
||||
MOZ_ASSERT(aType < ePseudo_PseudoElementCount);
|
||||
return PseudoElementHasFlags(aType, CSS_PSEUDO_ELEMENT_SUPPORTS_STYLE_ATTRIBUTE);
|
||||
}
|
||||
|
||||
static bool PseudoElementSupportsUserActionState(nsIAtom *aAtom) {
|
||||
return PseudoElementSupportsUserActionState(GetPseudoType(aAtom));
|
||||
}
|
||||
|
||||
static bool PseudoElementSupportsUserActionState(const Type aType);
|
||||
|
||||
static bool PseudoElementIsChromeOnly(const Type aType) {
|
||||
|
Loading…
Reference in New Issue
Block a user