diff options
author | Matt A. Tobin <email@mattatobin.com> | 2020-04-16 16:37:28 -0400 |
---|---|---|
committer | Matt A. Tobin <email@mattatobin.com> | 2020-04-16 16:37:28 -0400 |
commit | 4375774c901bac4bd1ecaa35b40f55397044b7e9 (patch) | |
tree | 5c1a39a427b89390ee5ae54f75b04fa6536fb4a4 /layout/forms/nsMeterFrame.cpp | |
parent | c66ed1275f1039fdf23a8f2c172d7c0b4691d1c2 (diff) | |
download | UXP-4375774c901bac4bd1ecaa35b40f55397044b7e9.tar UXP-4375774c901bac4bd1ecaa35b40f55397044b7e9.tar.gz UXP-4375774c901bac4bd1ecaa35b40f55397044b7e9.tar.lz UXP-4375774c901bac4bd1ecaa35b40f55397044b7e9.tar.xz UXP-4375774c901bac4bd1ecaa35b40f55397044b7e9.zip |
Bug 1331322 - Allow tagging of pseudo-implementing native anonymous content with the pseudo type at creation time
* Stop using a node bit for HasExplicitBaseURI
* Move MAY_HAVE_CLASS to mBoolFlags
* Add a flag to indicate that a node is native anonymous content
* Allow tagging of pseudo-implementing native anonymous content with the pseudo type at creation time, and eliminate explicit style contexts in nsIAnonymousContentCreator::ContentInfo
Tag #1375
Diffstat (limited to 'layout/forms/nsMeterFrame.cpp')
-rw-r--r-- | layout/forms/nsMeterFrame.cpp | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/layout/forms/nsMeterFrame.cpp b/layout/forms/nsMeterFrame.cpp index 1f3bd8022..6ef362820 100644 --- a/layout/forms/nsMeterFrame.cpp +++ b/layout/forms/nsMeterFrame.cpp @@ -75,14 +75,9 @@ nsMeterFrame::CreateAnonymousContent(nsTArray<ContentInfo>& aElements) mBarDiv = doc->CreateHTMLElement(nsGkAtoms::div); // Associate ::-moz-meter-bar pseudo-element to the anonymous child. - CSSPseudoElementType pseudoType = CSSPseudoElementType::mozMeterBar; - RefPtr<nsStyleContext> newStyleContext = PresContext()->StyleSet()-> - ResolvePseudoElementStyle(mContent->AsElement(), pseudoType, - StyleContext(), mBarDiv->AsElement()); + mBarDiv->SetPseudoElementType(CSSPseudoElementType::mozMeterBar); - if (!aElements.AppendElement(ContentInfo(mBarDiv, newStyleContext))) { - return NS_ERROR_OUT_OF_MEMORY; - } + aElements.AppendElement(mBarDiv); return NS_OK; } |