Bug 1294918 - Use helper method nsIFrame::IsFixedPosContainingBlock. r?dholbert
MozReview-Commit-ID: 5fdGqLSOjvs
--- a/layout/base/nsCSSFrameConstructor.cpp
+++ b/layout/base/nsCSSFrameConstructor.cpp
@@ -1068,17 +1068,17 @@ nsFrameConstructorState::PushAbsoluteCon
mAbsoluteItems =
nsAbsoluteItems(AdjustAbsoluteContainingBlock(aNewAbsoluteContainingBlock));
/* See if we're wiring the fixed-pos and abs-pos lists together. This happens iff
* we're a transformed element.
*/
mFixedPosIsAbsPos = aPositionedFrame &&
- aPositionedFrame->StyleDisplay()->IsFixedPosContainingBlock(aPositionedFrame);
+ aPositionedFrame->IsFixedPosContainingBlock();
if (aNewAbsoluteContainingBlock) {
aNewAbsoluteContainingBlock->MarkAsAbsoluteContainingBlock();
}
}
void
nsFrameConstructorState::PushFloatContainingBlock(nsContainerFrame* aNewFloatContainingBlock,
@@ -6148,17 +6148,17 @@ nsCSSFrameConstructor::GetAbsoluteContai
// parent frame, unless we're dealing with a scrollframe.
// Scrollframes are special since they're not positioned, but their
// scrolledframe might be. So, we need to check this special case to return
// the correct containing block (the scrolledframe) in that case.
// If we're looking for a fixed-pos containing block and the frame is
// not transformed, skip it.
if (!frame->IsAbsPosContainingBlock() ||
(aType == FIXED_POS &&
- !frame->StyleDisplay()->IsFixedPosContainingBlock(frame))) {
+ !frame->IsFixedPosContainingBlock())) {
continue;
}
nsIFrame* absPosCBCandidate = frame;
nsIAtom* type = absPosCBCandidate->GetType();
if (type == nsGkAtoms::fieldSetFrame) {
absPosCBCandidate = static_cast<nsFieldSetFrame*>(absPosCBCandidate)->GetInner();
if (!absPosCBCandidate) {
continue;