[LayoutNG] Better Legacy abspos handling

The major part of this commit is saving of static position for Legacy.
We used to save static position when fragment was added to its parent fragment.
This does not work for TextFragment in:

Box
  LineBox
    TextFragment

because Legacy expects TextFragment offset wrt Box, not LineBox.

This is fixed by setting static position when it is known wrt LayoutObject
LegacyLayout expects. The attempt to save happens in:

NGContainerFragmentBuilder::GetAndClearOutOfFlowDescendantCandidates
NGBlockNode only saves its offset if containing fragment matches Legacy expectation.

Minor part of this commit is initial steps for handling abspos inline fragments whose
containing block is Legacy. Previously, they were not handled as block fragments.
This patch does not complete this work, this is left as a TODO inside
NGOutOfFlowLayoutPart::ComputeInlineContainingBlocks. I need to figure out
how to compute these in Legacy code. But, there is a DCHECK that now triggers
in ~10 tests:
external/wpt/css/css-position/position-relative-table-tbody-left-absolute-child.html
....

Bug: 740993
Change-Id: Id8fd3be830799322746ddc0c6e0537c08bcfaeb7
Reviewed-on: https://chromium-review.googlesource.com/843018
Commit-Queue: Koji Ishii <kojii@chromium.org>
Reviewed-by: Koji Ishii <kojii@chromium.org>
Cr-Commit-Position: refs/heads/master@{#526171}
9 files changed