[LFC][Integration] Use the pre-computed geometries for the inline level boxes
https://bugs.webkit.org/show_bug.cgi?id=220135
<rdar://problem/72642850>

Reviewed by Antti Koivisto.

Let's skip the tree traversal and recomputing the box geometries in InlineFormattingContext::layoutInFlowContent.

* layout/FormattingContextGeometry.cpp:
(WebCore::Layout::FormattingContext::Geometry::inlineReplacedContentHeightAndMargin const):
(WebCore::Layout::FormattingContext::Geometry::inlineReplacedContentWidthAndMargin):
* layout/inlineformatting/InlineFormattingContext.h:
* layout/integration/LayoutIntegrationLineLayout.cpp:
(WebCore::LayoutIntegration::LineLayout::updateLayoutBoxDimensions):
(WebCore::LayoutIntegration::LineLayout::updateLineBreakBoxDimensions):
(WebCore::LayoutIntegration::LineLayout::layout):
* layout/integration/LayoutIntegrationLineLayout.h:
* layout/layouttree/LayoutReplacedBox.h:
(WebCore::Layout::ReplacedBox::contentSizeForIntegration const): Deleted.
(WebCore::Layout::ReplacedBox::setContentSizeForIntegration): Deleted.
* rendering/RenderBlockFlow.cpp:
(WebCore::RenderBlockFlow::layoutModernLines):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@271085 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/Source/WebCore/rendering/RenderBlockFlow.cpp b/Source/WebCore/rendering/RenderBlockFlow.cpp
index 3d84a8d..478acf8e 100644
--- a/Source/WebCore/rendering/RenderBlockFlow.cpp
+++ b/Source/WebCore/rendering/RenderBlockFlow.cpp
@@ -3638,6 +3638,12 @@
             continue;
         }
 
+        if (is<RenderLineBreak>(renderer)) {
+            layoutFormattingContextLineLayout.updateLineBreakBoxDimensions(downcast<RenderLineBreak>(renderer));
+            renderer.clearNeedsLayout();
+            continue;
+        }
+
         renderer.clearNeedsLayout();
     }