mirror of
https://repo.dactyloidae.xyz/Dactyloidae/UXP.git
synced 2026-09-29 03:47:31 +09:00
Revert "Support CSS shadow parts", it made browser crash
This reverts commit b2d422ae49.
This commit is contained in:
parent
b2d422ae49
commit
d636b76284
10 changed files with 32 additions and 167 deletions
|
|
@ -6959,8 +6959,6 @@ CSSParserImpl::ParsePseudoSelector(int32_t& aDataMask,
|
|||
if (hybridPseudoElementType == CSSPseudoElementType::slotted) {
|
||||
pseudoClassType = CSSPseudoClassType::slotted;
|
||||
aFlags |= SelectorParsingFlags::eDisallowCombinators;
|
||||
} else if (hybridPseudoElementType == CSSPseudoElementType::part) {
|
||||
pseudoClassType = CSSPseudoClassType::part;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -7113,28 +7111,6 @@ CSSParserImpl::ParsePseudoSelector(int32_t& aDataMask,
|
|||
UngetToken();
|
||||
return eSelectorParsingStatus_Error;
|
||||
}
|
||||
else if (hybridPseudoElementType != CSSPseudoElementType::NotPseudo) {
|
||||
aSelector.SetHybridPseudoType(hybridPseudoElementType);
|
||||
// Ensure hybrid pseudo-elements are rejected if they're not allowed.
|
||||
if (disallowPseudoElements) {
|
||||
UngetToken();
|
||||
return eSelectorParsingStatus_Error;
|
||||
}
|
||||
|
||||
if (nsCSSPseudoClasses::HasStringArg(pseudoClassType)) {
|
||||
parsingStatus =
|
||||
ParsePseudoClassWithIdentArg(aSelector, pseudoClassType);
|
||||
}
|
||||
else if (nsCSSPseudoClasses::HasSelectorListArg(pseudoClassType)) {
|
||||
parsingStatus = ParsePseudoClassWithSelectorListArg(aSelector,
|
||||
pseudoClassType,
|
||||
flags);
|
||||
}
|
||||
else {
|
||||
MOZ_ASSERT(false, "unexpected hybrid pseudo-element");
|
||||
parsingStatus = eSelectorParsingStatus_Error;
|
||||
}
|
||||
}
|
||||
else if (nsCSSPseudoClasses::HasStringArg(pseudoClassType)) {
|
||||
parsingStatus =
|
||||
ParsePseudoClassWithIdentArg(aSelector, pseudoClassType);
|
||||
|
|
@ -7146,6 +7122,14 @@ CSSParserImpl::ParsePseudoSelector(int32_t& aDataMask,
|
|||
else {
|
||||
MOZ_ASSERT(nsCSSPseudoClasses::HasSelectorListArg(pseudoClassType),
|
||||
"unexpected pseudo with function token");
|
||||
if (hybridPseudoElementType != CSSPseudoElementType::NotPseudo) {
|
||||
aSelector.SetHybridPseudoType(hybridPseudoElementType);
|
||||
// Ensure hybrid pseudo-elements are rejected if they're not allowed.
|
||||
if (disallowPseudoElements) {
|
||||
UngetToken();
|
||||
return eSelectorParsingStatus_Error;
|
||||
}
|
||||
}
|
||||
parsingStatus = ParsePseudoClassWithSelectorListArg(aSelector,
|
||||
pseudoClassType,
|
||||
flags);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue