Bug 1574552 - Push float/abs.pos. CB for 'block ruby' as needed. r=emilio

Differential Revision: https://phabricator.services.mozilla.com/D42701

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Mats Palmgren 2019-08-20 21:28:01 +00:00
parent 4ab1c12e2b
commit dd5a04bc1d
3 changed files with 19 additions and 0 deletions

View File

@ -3202,6 +3202,18 @@ nsIFrame* nsCSSFrameConstructor::ConstructBlockRubyFrame(
SetRootElementFrameAndConstructCanvasAnonContent(newFrame, aState,
aFrameList);
}
nsFrameConstructorSaveState absoluteSaveState;
blockFrame->AddStateBits(NS_FRAME_CAN_HAVE_ABSPOS_CHILDREN);
if (aStyleDisplay->IsAbsPosContainingBlock(newFrame)) {
aState.PushAbsoluteContainingBlock(blockFrame, blockFrame,
absoluteSaveState);
}
nsFrameConstructorSaveState floatSaveState;
if (blockFrame->IsFloatContainingBlock()) {
aState.PushFloatContainingBlock(blockFrame, floatSaveState);
}
nsFrameList childList;
ProcessChildren(aState, content, rubyStyle, rubyFrame, true, childList, false,
nullptr);

View File

@ -0,0 +1,6 @@
<style>
* { float: right }
</style>
<ruby>
<table>
A

View File

@ -736,3 +736,4 @@ load 1346454-2.html
load 1555142.html
load 1562105.html
load 1571460.html
load 1574552.html