Bug 1321394 - Remove unnecessary loop in nsRubyBaseContainerFrame. r=dholbert

MozReview-Commit-ID: DqRD0w823Sv

--HG--
extra : rebase_source : 5d4e55c12a411e9f0c3579eca362d0b793aef445
This commit is contained in:
Xidorn Quan 2016-12-01 13:47:26 +11:00
parent ca5083ce4d
commit 6dc3678ea2

View File

@ -769,11 +769,10 @@ nsRubyBaseContainerFrame::PullOneColumn(nsLineLayout* aLineLayout,
// We are not pulling an intra-level whitespace, which means all
// elements we are going to pull can have non-whitespace content,
// which may contain float which we need to reparent.
nsBlockFrame* oldFloatCB = nullptr;
for (nsIFrame* frame : aColumn) {
oldFloatCB = nsLayoutUtils::GetFloatContainingBlock(frame);
break;
}
MOZ_ASSERT(aColumn.begin() != aColumn.end(),
"Ruby column shouldn't be empty");
nsBlockFrame* oldFloatCB =
nsLayoutUtils::GetFloatContainingBlock(*aColumn.begin());
#ifdef DEBUG
MOZ_ASSERT(oldFloatCB, "Must have found a float containing block");
for (nsIFrame* frame : aColumn) {