[webkit-changes] [WebKit/WebKit] 06fa3e: Fix broken preferred widths optimization involving...

Ahmad Saleem noreply at github.com
Sun Nov 13 16:58:05 PST 2022


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 06fa3e82eb2e0267284e9c57342078a070e8016c
      https://github.com/WebKit/WebKit/commit/06fa3e82eb2e0267284e9c57342078a070e8016c
  Author: Ahmad Saleem <ahmad.saleem792+github at gmail.com>
  Date:   2022-11-13 (Sun, 13 Nov 2022)

  Changed paths:
    A LayoutTests/fast/layout/nested-subtree-layout-preferred-widths-expected.txt
    A LayoutTests/fast/layout/nested-subtree-layout-preferred-widths.html
    M LayoutTests/imported/w3c/web-platform-tests/css/css-sizing/contain-intrinsic-size/auto-006-expected.txt
    M LayoutTests/imported/w3c/web-platform-tests/css/css-sizing/contain-intrinsic-size/auto-010-expected.txt
    M Source/WebCore/rendering/RenderBox.cpp

  Log Message:
  -----------
  Fix broken preferred widths optimization involving subtree layout roots

Fix broken preferred widths optimization involving subtree layout roots
https://bugs.webkit.org/show_bug.cgi?id=247742

Reviewed by Alan Baradlay.

Merge - https://chromium.googlesource.com/chromium/blink/+/ed902d339fbff3a62e2f6124d8d40bbad45e97c0

This patch is to remove optimization or fix introduced in 2006, which is about RenderBox::computePreferredLogicalWidths
to bail when in a subtree layout.
This can result in a box not updating its preferred widths even when it
should in the case that its a subtree layout root that was marked for layout
of its children, then subsequently marked for layout itself.

* Source/WebCore/rendering/RenderBox.cpp:
(RenderBox:computeLogicalWidthInFragment): Remove "subtree' layout optimization
* LayoutTests/fast/layout/nested-subtree-layout-preferred-widths.html: Added Test Case
* LayoutTests/fast/layout/nested-subtree-layout-preferred-widths-expected.html: Added Test Case Expectation
* LayoutTests/imported/w3c/web-platform-tests/css/css-sizing/contain-intrinsic-size/auto-006-expected.txt: Updated Test Expectations
* LayoutTests/imported/w3c/web-platform-tests/css/css-sizing/contain-intrinsic-size/auto-010-expected.txt: Ditto

Canonical link: https://commits.webkit.org/256623@main




More information about the webkit-changes mailing list