Bug 1634840 - Remove warning about inlines in XUL. r=dbaron
It's not like we're going to change behavior here anytime soon anymore (other than removing XUL usage), and the helpfulness of the warning has probably decreased with time. But maybe I'm missing a reason why it should be kept around? Differential Revision: https://phabricator.services.mozilla.com/D73544
This commit is contained in:
@@ -9678,27 +9678,9 @@ void nsCSSFrameConstructor::ProcessChildren(
|
||||
// XXXbz we could do this on the FrameConstructionItemList level,
|
||||
// no? And if we cared we could look through the item list
|
||||
// instead of groveling through the framelist here..
|
||||
ComputedStyle* frameComputedStyle = aFrame->Style();
|
||||
// Report a warning for non-GC frames, for chrome:
|
||||
if (!aFrame->IsGeneratedContentFrame() &&
|
||||
mPresShell->GetPresContext()->IsChrome()) {
|
||||
nsIContent* badKid = AnyKidsNeedBlockParent(aFrameList.FirstChild());
|
||||
AutoTArray<nsString, 2> params = {
|
||||
nsDependentAtomString(aContent->NodeInfo()->NameAtom()),
|
||||
nsDependentAtomString(badKid->NodeInfo()->NameAtom())};
|
||||
const nsStyleDisplay* display = frameComputedStyle->StyleDisplay();
|
||||
const char* message = (display->mDisplay == StyleDisplay::MozInlineBox)
|
||||
? "NeededToWrapXULInlineBox"
|
||||
: "NeededToWrapXUL";
|
||||
nsContentUtils::ReportToConsole(
|
||||
nsIScriptError::warningFlag,
|
||||
NS_LITERAL_CSTRING("Layout: FrameConstructor"), mDocument,
|
||||
nsContentUtils::eXUL_PROPERTIES, message, params);
|
||||
}
|
||||
|
||||
RefPtr<ComputedStyle> blockSC =
|
||||
mPresShell->StyleSet()->ResolveInheritingAnonymousBoxStyle(
|
||||
PseudoStyleType::mozXULAnonymousBlock, frameComputedStyle);
|
||||
PseudoStyleType::mozXULAnonymousBlock, aFrame->Style());
|
||||
nsBlockFrame* blockFrame = NS_NewBlockFrame(mPresShell, blockSC);
|
||||
// We might, in theory, want to set NS_BLOCK_FLOAT_MGR and
|
||||
// NS_BLOCK_MARGIN_ROOT, but I think it's a bad idea given that
|
||||
|
||||
Reference in New Issue
Block a user