Bug 1821603 - Fix writing-mode mismatch in visibility: collapse handling. r=TYLin

Differential Revision: https://phabricator.services.mozilla.com/D172438
This commit is contained in:
Emilio Cobos Álvarez 2023-03-13 22:19:47 +00:00
parent 6c095148a2
commit c0f66baed0
3 changed files with 6 additions and 1 deletions

View File

@ -0,0 +1,4 @@
<!doctype html>
<div style="display: flex">
<div style="visibility: collapse; direction: rtl"></div>
</div>

View File

@ -818,3 +818,4 @@ asserts(0-2) load 1791606.html
load 1799749.html
pref(layout.css.content-visibility.enabled,true) asserts(1-4) load 1807958.html # asserts from integer overflow & bogus sizes
load 1816574.html
load 1821603.html

View File

@ -2155,7 +2155,7 @@ FlexItem::FlexItem(nsIFrame* aChildFrame, nscoord aCrossSize,
WritingMode aContainerWM,
const FlexboxAxisTracker& aAxisTracker)
: mFrame(aChildFrame),
mWM(aContainerWM),
mWM(aChildFrame->GetWritingMode()),
mCBWM(aContainerWM),
mMainAxis(aAxisTracker.MainAxis()),
mBorderPadding(mCBWM),