Issue #2111 - Implement CSSStyleRule.selectorText setter

Unlike the original patch, this copies Chrome behavior: ignores invalid values of selectorText without any console log.

Partially based on https://bugzilla.mozilla.org/show_bug.cgi?id=37468
This commit is contained in:
FranklinDM 2023-02-20 11:20:23 +08:00 committed by roytam1
commit 6d3500bb48
4 changed files with 45 additions and 3 deletions

View file

@ -1618,6 +1618,12 @@ CSSStyleSheet::DidDirty()
ClearRuleCascades();
}
void
CSSStyleSheet::AssertHasUniqueInner()
{
MOZ_ASSERT(mInner->mSheets.Length() == 1, "expected unique inner");
}
nsresult
CSSStyleSheet::RegisterNamespaceRule(css::Rule* aRule)
{