[LayoutNG] Orthogonal flows need available inline size for min/max calculation.
Provide a suitable constraint space when calculating min/max inline sizes for an orthogonal flow root. ComputeMinMaxSize() in NGBlockNode typically ended up creating its zero-sized constraint space, which would typically result in large block sizes (since there'd e.g. only be space for one word per line). Set percentage resolution size too, instead of leaving it at 0x0. Percentages are often unresolvable (i.e. indefinite), in which case we should of course refrain from resolving them, rather than resolving the percentage against zero (which we used to do). Add a DCHECK that we're always provided with a constraint space when calculating min/max for orthogonal flows, as using the zero-size one will not produce the correct result. Bug: 848225 Cq-Include-Trybots: master.tryserver.chromium.linux:linux_layout_tests_layout_ng Change-Id: Ic0aac380b2b733d3a55b25396c89584e4468899d Reviewed-on: https://chromium-review.googlesource.com/1090845 Commit-Queue: Morten Stenshorne <mstensho@chromium.org> Reviewed-by:Aleks Totic <atotic@chromium.org> Reviewed-by:
Koji Ishii <kojii@chromium.org> Reviewed-by:
Christian Biesinger <cbiesinger@chromium.org> Cr-Commit-Position: refs/heads/master@{#565446}
Showing
Please register or sign in to comment