mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-25 13:51:41 +00:00
Bug 1489295 Part 4 - Remove InitAndWrapInColumnSetFrameIfNeeded(). r=dbaron
The last consumer of the method is removed in Part 3. Depends on D24396 Differential Revision: https://phabricator.services.mozilla.com/D24470 --HG-- extra : moz-landing-system : lando
This commit is contained in:
parent
11a3e0712a
commit
5bef4c66dd
@ -10498,34 +10498,6 @@ void nsCSSFrameConstructor::RecoverLetterFrames(nsContainerFrame* aBlockFrame) {
|
||||
|
||||
//----------------------------------------------------------------------
|
||||
|
||||
nsContainerFrame* nsCSSFrameConstructor::InitAndWrapInColumnSetFrameIfNeeded(
|
||||
nsFrameConstructorState& aState, nsIContent* aContent,
|
||||
nsContainerFrame* aParentFrame, nsContainerFrame* aBlockFrame,
|
||||
ComputedStyle* aComputedStyle) {
|
||||
MOZ_ASSERT((aBlockFrame->IsBlockFrame() || aBlockFrame->IsDetailsFrame()),
|
||||
"aBlockFrame should either be a block frame or a details frame.");
|
||||
|
||||
if (!aComputedStyle->StyleColumn()->IsColumnContainerStyle()) {
|
||||
aBlockFrame->SetComputedStyleWithoutNotification(aComputedStyle);
|
||||
InitAndRestoreFrame(aState, aContent, aParentFrame, aBlockFrame);
|
||||
return aBlockFrame;
|
||||
}
|
||||
|
||||
// Wrap the block frame in a ColumnSetFrame.
|
||||
nsContainerFrame* columnSetFrame = NS_NewColumnSetFrame(
|
||||
mPresShell, aComputedStyle, nsFrameState(NS_FRAME_OWNS_ANON_BOXES));
|
||||
InitAndRestoreFrame(aState, aContent, aParentFrame, columnSetFrame);
|
||||
SetInitialSingleChild(columnSetFrame, aBlockFrame);
|
||||
|
||||
RefPtr<ComputedStyle> anonBlockStyle =
|
||||
mPresShell->StyleSet()->ResolveInheritingAnonymousBoxStyle(
|
||||
PseudoStyleType::columnContent, aComputedStyle);
|
||||
aBlockFrame->SetComputedStyleWithoutNotification(anonBlockStyle);
|
||||
InitAndRestoreFrame(aState, aContent, columnSetFrame, aBlockFrame);
|
||||
|
||||
return columnSetFrame;
|
||||
}
|
||||
|
||||
void nsCSSFrameConstructor::ConstructBlock(
|
||||
nsFrameConstructorState& aState, nsIContent* aContent,
|
||||
nsContainerFrame* aParentFrame, nsContainerFrame* aContentParentFrame,
|
||||
|
@ -1775,22 +1775,6 @@ class nsCSSFrameConstructor final : public nsFrameManager {
|
||||
bool* aHaveFirstLetterStyle,
|
||||
bool* aHaveFirstLineStyle);
|
||||
|
||||
// Initialize aBlockFrame, and wrap it in a ColumnSetFrame if needed.
|
||||
//
|
||||
// If a ColumnSetFrame needs to be created, then this function will create
|
||||
// one, and set aBlockFrame as its child (with an updated "columnContent"
|
||||
// ComputedStyle() pointer), and initialize both frames. Otherwise, it
|
||||
// initializes aBlockFrame.
|
||||
//
|
||||
// @return the new ColumnSetFrame if needed; otherwise aBlockFrame.
|
||||
//
|
||||
// FIXME (Bug 1489295): Callers using this function to create multi-column
|
||||
// hierarchy should be revised to support column-span.
|
||||
nsContainerFrame* InitAndWrapInColumnSetFrameIfNeeded(
|
||||
nsFrameConstructorState& aState, nsIContent* aContent,
|
||||
nsContainerFrame* aParentFrame, nsContainerFrame* aBlockFrame,
|
||||
ComputedStyle* aComputedStyle);
|
||||
|
||||
// |aContentParentFrame| should be null if it's really the same as
|
||||
// |aParentFrame|.
|
||||
// @param aFrameItems where we want to put the block in case it's in-flow.
|
||||
|
Loading…
Reference in New Issue
Block a user