Bug 1415152: No need for AdjustAppendForAfter, since ::after is handled in FindNextSibling. r=mats

MozReview-Commit-ID: 5jfJul3cJj3

--HG--
extra : rebase_source : eea1a58b0059ef17724e092dbc473861e7d80d5c
This commit is contained in:
Emilio Cobos Álvarez 2017-11-06 18:56:00 +01:00
Родитель 75d775e622
Коммит 13ad569c28
1 изменённых файлов: 3 добавлений и 10 удалений

Просмотреть файл

@ -7072,8 +7072,7 @@ nsCSSFrameConstructor::GetInsertionPrevSibling(InsertionPoint* aInsertion,
iter.Seek(aEndSkipChild);
iter.GetPreviousChild();
}
nsIFrame* nextSibling = FindNextSibling(iter, childDisplay);
if (nextSibling) {
if (nsIFrame* nextSibling = FindNextSibling(iter, childDisplay)) {
aInsertion->mParentFrame = nextSibling->GetParent()->GetContentInsertionFrame();
} else {
// No previous or next sibling, so treat this like an appended frame.
@ -7085,19 +7084,13 @@ nsCSSFrameConstructor::GetInsertionPrevSibling(InsertionPoint* aInsertion,
aInsertion->mParentFrame =
GetLastIBSplitSibling(aInsertion->mParentFrame, false);
}
// Get continuation that parents the last child. This MUST be done
// before the AdjustAppendParentForAfterContent call.
// Get continuation that parents the last child.
aInsertion->mParentFrame =
nsLayoutUtils::LastContinuationWithChild(aInsertion->mParentFrame);
// Deal with fieldsets
aInsertion->mParentFrame =
::GetAdjustedParentFrame(aInsertion->mParentFrame, aChild);
nsIFrame* appendAfterFrame;
aInsertion->mParentFrame =
::AdjustAppendParentForAfterContent(this, aInsertion->mContainer,
aInsertion->mParentFrame,
aChild, &appendAfterFrame);
prevSibling = ::FindAppendPrevSibling(aInsertion->mParentFrame, appendAfterFrame);
prevSibling = ::FindAppendPrevSibling(aInsertion->mParentFrame, nullptr);
}
}