Commit 1368fb50 authored by Morten Stenshorne's avatar Morten Stenshorne Committed by Commit Bot

[LayoutNG] RT elements must fall back to legacy layout.

Normally, an RT element is somewhere inside a RUBY element. We already
force legacy layout for the entire subtree established by RUBY elements,
but we need to do the same for RT elements, in case they don't have a
RUBY ancestor. RT elements create a special legacy layout object,
without necessarily establishing a new formatting context.

Bug: 967255
Change-Id: I35857fdeced55ee10a385b58b117f28007bd7791
Cq-Include-Trybots: luci.chromium.try:linux_layout_tests_layout_ng
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1632261
Commit-Queue: Morten Stenshorne <mstensho@chromium.org>
Commit-Queue: Emil A Eklund <eae@chromium.org>
Reviewed-by: default avatarEmil A Eklund <eae@chromium.org>
Cr-Commit-Position: refs/heads/master@{#664014}
parent 613ca444
......@@ -17,6 +17,7 @@ class HTMLRTElement final : public HTMLElement {
private:
LayoutObject* CreateLayoutObject(const ComputedStyle&, LegacyLayout) override;
bool TypeShouldForceLegacyLayout() const final { return true; }
};
} // namespace blink
......
<!DOCTYPE html>
<link rel="author" title="Morten Stenshorne" href="mailto:mstensho@chromium.org">
<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=967255">
<rt style="display:block;">
<div></div>
</rt>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script>
test(()=> { }, "No crash");
</script>
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment