Don't miss list item markers inside multicol containers. #28839
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
With list-style-position:inside, we'd fail to find the marker if it was
inside a multicol container, because we'd look for it in the flow
thread, and give up, since the flow thread isn't the list-item (the
multicol container (the parent LayoutObject) is).
Flow threads should be ignored in LayoutNG. Use
GetLayoutObjectForParentNode() if we need to walk up the tree, to get
this right. Templatize GetLayoutObjectForParentNode(), so that it can
provide both a const and non-const version. CollectInlinesInternal()
works on non-const objects, and there doesn't seem to be an easy way
around that.
This fixes the final failures in multicol-span-all-list-item-001.html
and multicol-span-all-list-item-002.html, but since those tests were
quite complicated (and mostly about spanners, even if this CL has
nothing to do with spanners), I added a simpler test for this specific
issue.
Bug: 829028, 1130451
Change-Id: I6bcf10593a68c40cbc9adc11f9572c9aee580623
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2874650
Commit-Queue: Morten Stenshorne <mstensho@chromium.org>
Reviewed-by: Koji Ishii <kojii@chromium.org>
Cr-Commit-Position: refs/heads/master@{#881621}