Rename LayoutState to RenderLayoutState
authorantti@apple.com <antti@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 7 Dec 2018 20:10:14 +0000 (20:10 +0000)
committerantti@apple.com <antti@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 7 Dec 2018 20:10:14 +0000 (20:10 +0000)
https://bugs.webkit.org/show_bug.cgi?id=192504

Reviewed by Zalan Bujtas.

The name is better used in LFC.

* Sources.txt:
* WebCore.xcodeproj/project.pbxproj:
* page/FrameViewLayoutContext.cpp:
(WebCore::FrameViewLayoutContext::layoutState const):
(WebCore::FrameViewLayoutContext::pushLayoutState):
(WebCore::FrameViewLayoutContext::pushLayoutStateForPaginationIfNeeded):
* page/FrameViewLayoutContext.h:
* rendering/LayoutState.cpp: Removed.
* rendering/LayoutState.h: Removed.
* rendering/RenderBlock.cpp:
* rendering/RenderBlock.h:
* rendering/RenderBlockFlow.cpp:
(WebCore::RenderBlockFlow::checkForPaginationLogicalHeightChange):
* rendering/RenderBlockLineLayout.cpp:
* rendering/RenderBox.cpp:
* rendering/RenderEmbeddedObject.cpp:
* rendering/RenderFragmentedFlow.cpp:
* rendering/RenderGrid.cpp:
* rendering/RenderImage.cpp:
* rendering/RenderInline.cpp:
* rendering/RenderLayoutState.cpp: Copied from Source/WebCore/rendering/LayoutState.cpp.
(WebCore::RenderLayoutState::RenderLayoutState):
(WebCore::RenderLayoutState::computeOffsets):
(WebCore::RenderLayoutState::computeClipRect):
(WebCore::RenderLayoutState::computePaginationInformation):
(WebCore::RenderLayoutState::pageLogicalOffset const):
(WebCore::RenderLayoutState::computeLineGridPaginationOrigin):
(WebCore::RenderLayoutState::propagateLineGridInfo):
(WebCore::RenderLayoutState::establishLineGrid):
(WebCore::RenderLayoutState::addLayoutDelta):
(WebCore::RenderLayoutState::layoutDeltaMatches const):
(WebCore::LayoutState::LayoutState): Deleted.
(WebCore::LayoutState::computeOffsets): Deleted.
(WebCore::LayoutState::computeClipRect): Deleted.
(WebCore::LayoutState::computePaginationInformation): Deleted.
(WebCore::LayoutState::pageLogicalOffset const): Deleted.
(WebCore::LayoutState::computeLineGridPaginationOrigin): Deleted.
(WebCore::LayoutState::propagateLineGridInfo): Deleted.
(WebCore::LayoutState::establishLineGrid): Deleted.
(WebCore::LayoutState::addLayoutDelta): Deleted.
(WebCore::LayoutState::layoutDeltaMatches const): Deleted.
* rendering/RenderLayoutState.h: Copied from Source/WebCore/rendering/LayoutState.h.
(WebCore::RenderLayoutState::RenderLayoutState):
(WebCore::LayoutState::LayoutState): Deleted.
(WebCore::LayoutState::isPaginated const): Deleted.
(WebCore::LayoutState::pageLogicalHeight const): Deleted.
(WebCore::LayoutState::pageLogicalHeightChanged const): Deleted.
(WebCore::LayoutState::lineGrid const): Deleted.
(WebCore::LayoutState::lineGridOffset const): Deleted.
(WebCore::LayoutState::lineGridPaginationOrigin const): Deleted.
(WebCore::LayoutState::paintOffset const): Deleted.
(WebCore::LayoutState::layoutOffset const): Deleted.
(WebCore::LayoutState::pageOffset const): Deleted.
(WebCore::LayoutState::needsBlockDirectionLocationSetBeforeLayout const): Deleted.
(WebCore::LayoutState::renderer const): Deleted.
(WebCore::LayoutState::clipRect const): Deleted.
(WebCore::LayoutState::isClipped const): Deleted.
(WebCore::LayoutState::layoutDelta const): Deleted.
* rendering/RenderListBox.cpp:
* rendering/RenderMediaControlElements.cpp:
* rendering/RenderMultiColumnFlow.cpp:
* rendering/RenderTable.cpp:
* rendering/RenderTableRow.cpp:
* rendering/RenderTableSection.cpp:
* rendering/RenderVTTCue.cpp:
* rendering/RenderView.cpp:
* rendering/RenderView.h:
* rendering/RootInlineBox.cpp:
* rendering/svg/RenderSVGRoot.cpp:
(WebCore::RenderSVGRoot::layout):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@238963 268f45cc-cd09-0410-ab3c-d52691b4dbfc

28 files changed:
Source/WebCore/ChangeLog
Source/WebCore/Sources.txt
Source/WebCore/WebCore.xcodeproj/project.pbxproj
Source/WebCore/page/FrameViewLayoutContext.cpp
Source/WebCore/page/FrameViewLayoutContext.h
Source/WebCore/rendering/RenderBlock.cpp
Source/WebCore/rendering/RenderBlock.h
Source/WebCore/rendering/RenderBlockFlow.cpp
Source/WebCore/rendering/RenderBlockLineLayout.cpp
Source/WebCore/rendering/RenderBox.cpp
Source/WebCore/rendering/RenderEmbeddedObject.cpp
Source/WebCore/rendering/RenderFragmentedFlow.cpp
Source/WebCore/rendering/RenderGrid.cpp
Source/WebCore/rendering/RenderImage.cpp
Source/WebCore/rendering/RenderInline.cpp
Source/WebCore/rendering/RenderLayoutState.cpp [moved from Source/WebCore/rendering/LayoutState.cpp with 91% similarity]
Source/WebCore/rendering/RenderLayoutState.h [moved from Source/WebCore/rendering/LayoutState.h with 91% similarity]
Source/WebCore/rendering/RenderListBox.cpp
Source/WebCore/rendering/RenderMediaControlElements.cpp
Source/WebCore/rendering/RenderMultiColumnFlow.cpp
Source/WebCore/rendering/RenderTable.cpp
Source/WebCore/rendering/RenderTableRow.cpp
Source/WebCore/rendering/RenderTableSection.cpp
Source/WebCore/rendering/RenderVTTCue.cpp
Source/WebCore/rendering/RenderView.cpp
Source/WebCore/rendering/RenderView.h
Source/WebCore/rendering/RootInlineBox.cpp
Source/WebCore/rendering/svg/RenderSVGRoot.cpp

index 6b00a71..764c2c3 100644 (file)
@@ -1,5 +1,85 @@
 2018-12-07  Antti Koivisto  <antti@apple.com>
 
+        Rename LayoutState to RenderLayoutState
+        https://bugs.webkit.org/show_bug.cgi?id=192504
+
+        Reviewed by Zalan Bujtas.
+
+        The name is better used in LFC.
+
+        * Sources.txt:
+        * WebCore.xcodeproj/project.pbxproj:
+        * page/FrameViewLayoutContext.cpp:
+        (WebCore::FrameViewLayoutContext::layoutState const):
+        (WebCore::FrameViewLayoutContext::pushLayoutState):
+        (WebCore::FrameViewLayoutContext::pushLayoutStateForPaginationIfNeeded):
+        * page/FrameViewLayoutContext.h:
+        * rendering/LayoutState.cpp: Removed.
+        * rendering/LayoutState.h: Removed.
+        * rendering/RenderBlock.cpp:
+        * rendering/RenderBlock.h:
+        * rendering/RenderBlockFlow.cpp:
+        (WebCore::RenderBlockFlow::checkForPaginationLogicalHeightChange):
+        * rendering/RenderBlockLineLayout.cpp:
+        * rendering/RenderBox.cpp:
+        * rendering/RenderEmbeddedObject.cpp:
+        * rendering/RenderFragmentedFlow.cpp:
+        * rendering/RenderGrid.cpp:
+        * rendering/RenderImage.cpp:
+        * rendering/RenderInline.cpp:
+        * rendering/RenderLayoutState.cpp: Copied from Source/WebCore/rendering/LayoutState.cpp.
+        (WebCore::RenderLayoutState::RenderLayoutState):
+        (WebCore::RenderLayoutState::computeOffsets):
+        (WebCore::RenderLayoutState::computeClipRect):
+        (WebCore::RenderLayoutState::computePaginationInformation):
+        (WebCore::RenderLayoutState::pageLogicalOffset const):
+        (WebCore::RenderLayoutState::computeLineGridPaginationOrigin):
+        (WebCore::RenderLayoutState::propagateLineGridInfo):
+        (WebCore::RenderLayoutState::establishLineGrid):
+        (WebCore::RenderLayoutState::addLayoutDelta):
+        (WebCore::RenderLayoutState::layoutDeltaMatches const):
+        (WebCore::LayoutState::LayoutState): Deleted.
+        (WebCore::LayoutState::computeOffsets): Deleted.
+        (WebCore::LayoutState::computeClipRect): Deleted.
+        (WebCore::LayoutState::computePaginationInformation): Deleted.
+        (WebCore::LayoutState::pageLogicalOffset const): Deleted.
+        (WebCore::LayoutState::computeLineGridPaginationOrigin): Deleted.
+        (WebCore::LayoutState::propagateLineGridInfo): Deleted.
+        (WebCore::LayoutState::establishLineGrid): Deleted.
+        (WebCore::LayoutState::addLayoutDelta): Deleted.
+        (WebCore::LayoutState::layoutDeltaMatches const): Deleted.
+        * rendering/RenderLayoutState.h: Copied from Source/WebCore/rendering/LayoutState.h.
+        (WebCore::RenderLayoutState::RenderLayoutState):
+        (WebCore::LayoutState::LayoutState): Deleted.
+        (WebCore::LayoutState::isPaginated const): Deleted.
+        (WebCore::LayoutState::pageLogicalHeight const): Deleted.
+        (WebCore::LayoutState::pageLogicalHeightChanged const): Deleted.
+        (WebCore::LayoutState::lineGrid const): Deleted.
+        (WebCore::LayoutState::lineGridOffset const): Deleted.
+        (WebCore::LayoutState::lineGridPaginationOrigin const): Deleted.
+        (WebCore::LayoutState::paintOffset const): Deleted.
+        (WebCore::LayoutState::layoutOffset const): Deleted.
+        (WebCore::LayoutState::pageOffset const): Deleted.
+        (WebCore::LayoutState::needsBlockDirectionLocationSetBeforeLayout const): Deleted.
+        (WebCore::LayoutState::renderer const): Deleted.
+        (WebCore::LayoutState::clipRect const): Deleted.
+        (WebCore::LayoutState::isClipped const): Deleted.
+        (WebCore::LayoutState::layoutDelta const): Deleted.
+        * rendering/RenderListBox.cpp:
+        * rendering/RenderMediaControlElements.cpp:
+        * rendering/RenderMultiColumnFlow.cpp:
+        * rendering/RenderTable.cpp:
+        * rendering/RenderTableRow.cpp:
+        * rendering/RenderTableSection.cpp:
+        * rendering/RenderVTTCue.cpp:
+        * rendering/RenderView.cpp:
+        * rendering/RenderView.h:
+        * rendering/RootInlineBox.cpp:
+        * rendering/svg/RenderSVGRoot.cpp:
+        (WebCore::RenderSVGRoot::layout):
+
+2018-12-07  Antti Koivisto  <antti@apple.com>
+
         [LFC] Rename formattingContext() to createFormattingContext()
         https://bugs.webkit.org/show_bug.cgi?id=192500
 
index 3146462..4c03020 100644 (file)
@@ -1917,7 +1917,6 @@ rendering/InlineIterator.cpp
 rendering/InlineTextBox.cpp
 rendering/LayoutDisallowedScope.cpp
 rendering/LayoutRepainter.cpp
-rendering/LayoutState.cpp
 rendering/MarkedText.cpp
 rendering/OrderIterator.cpp
 rendering/PointerEventsHitRules.cpp
@@ -1956,6 +1955,7 @@ rendering/RenderLayerBacking.cpp
 rendering/RenderLayerCompositor.cpp
 rendering/RenderLayerFilters.cpp
 rendering/RenderLayerModelObject.cpp
+rendering/RenderLayoutState.cpp
 rendering/RenderLineBoxList.cpp
 rendering/RenderLineBreak.cpp
 rendering/RenderListBox.cpp
index bea0e3e..c123c49 100644 (file)
                2D8B92FE203D13E1009C868F /* UnifiedSource529.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DE5F85CF1FA23850006DB63B /* UnifiedSource529.cpp */; };
                2D8B92FF203D13E1009C868F /* UnifiedSource530.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DE5F85D31FA23859006DB63B /* UnifiedSource530.cpp */; };
                2D8FEBDD143E3EF70072502B /* CSSCrossfadeValue.h in Headers */ = {isa = PBXBuildFile; fileRef = 2D8FEBDB143E3EF70072502B /* CSSCrossfadeValue.h */; };
-               2D9066070BE141D400956998 /* LayoutState.h in Headers */ = {isa = PBXBuildFile; fileRef = 2D9066050BE141D400956998 /* LayoutState.h */; settings = {ATTRIBUTES = (Private, ); }; };
+               2D9066070BE141D400956998 /* RenderLayoutState.h in Headers */ = {isa = PBXBuildFile; fileRef = 2D9066050BE141D400956998 /* RenderLayoutState.h */; settings = {ATTRIBUTES = (Private, ); }; };
                2D92A79A2134AD7900F493FD /* QuickLookSoftLink.mm in Sources */ = {isa = PBXBuildFile; fileRef = 443917FD1A91B2F8006E04F2 /* QuickLookSoftLink.mm */; };
                2D92A79D2134AF9500F493FD /* UserAgentIOS.mm in Sources */ = {isa = PBXBuildFile; fileRef = A3AF9D8320325691006CAD06 /* UserAgentIOS.mm */; };
                2D93AEE319DF5641002A86C3 /* ServicesOverlayController.h in Headers */ = {isa = PBXBuildFile; fileRef = 2D93AEE119DF5641002A86C3 /* ServicesOverlayController.h */; };
                2D8287F516E4A0380086BD00 /* HitTestLocation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = HitTestLocation.h; sourceTree = "<group>"; };
                2D8FEBDA143E3EF70072502B /* CSSCrossfadeValue.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CSSCrossfadeValue.cpp; sourceTree = "<group>"; };
                2D8FEBDB143E3EF70072502B /* CSSCrossfadeValue.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CSSCrossfadeValue.h; sourceTree = "<group>"; };
-               2D9066040BE141D400956998 /* LayoutState.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = LayoutState.cpp; sourceTree = "<group>"; };
-               2D9066050BE141D400956998 /* LayoutState.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = LayoutState.h; sourceTree = "<group>"; };
+               2D9066040BE141D400956998 /* RenderLayoutState.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = RenderLayoutState.cpp; sourceTree = "<group>"; };
+               2D9066050BE141D400956998 /* RenderLayoutState.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = RenderLayoutState.h; sourceTree = "<group>"; };
                2D90660C0665D937006B6F1A /* DataTransferMac.mm */ = {isa = PBXFileReference; fileEncoding = 30; indentWidth = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = DataTransferMac.mm; sourceTree = "<group>"; tabWidth = 8; usesTabs = 0; };
                2D93AEE119DF5641002A86C3 /* ServicesOverlayController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ServicesOverlayController.h; sourceTree = "<group>"; };
                2D93AEE219DF5641002A86C3 /* ServicesOverlayController.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = ServicesOverlayController.mm; sourceTree = "<group>"; };
                                9BD1F6801F0462B8001C9CDD /* LayoutDisallowedScope.h */,
                                A120ACA113F9984600FE4AC7 /* LayoutRepainter.cpp */,
                                A120ACA013F9983700FE4AC7 /* LayoutRepainter.h */,
-                               2D9066040BE141D400956998 /* LayoutState.cpp */,
-                               2D9066050BE141D400956998 /* LayoutState.h */,
                                9BA273F3172206BB0097CE47 /* LogicalSelectionOffsetCaches.h */,
                                CE1866421F72E5B400A0CAB6 /* MarkedText.cpp */,
                                CE1866431F72E5B400A0CAB6 /* MarkedText.h */,
                                0F53FB89213B768400C40D34 /* RenderLayerFilters.h */,
                                3C244FE5A375AC633F88BE6F /* RenderLayerModelObject.cpp */,
                                3C244FE4A375AC633F88BE6F /* RenderLayerModelObject.h */,
+                               2D9066040BE141D400956998 /* RenderLayoutState.cpp */,
+                               2D9066050BE141D400956998 /* RenderLayoutState.h */,
                                BC33FB1A0F30EE85002CDD7C /* RenderLineBoxList.cpp */,
                                0BE030A10F3112FB003C1A46 /* RenderLineBoxList.h */,
                                BCEA4824097D93020094C9E4 /* RenderLineBreak.cpp */,
                                CD318623199F1E2A0030A0F7 /* CDMPrivateMediaSourceAVFObjC.h in Headers */,
                                CDE595971BF26E2100A1CBE8 /* CDMSessionMediaSourceAVFObjC.h in Headers */,
                                5FA904CA178E61F5004C8A2D /* CertificateInfo.h in Headers */,
-                                91B8F0B521953D65000C2B00 /* CertificateInfoBase.h in Headers */,
-                                FE36FD1516C7826500F887C1 /* ChangeVersionData.h in Headers */,
+                               91B8F0B521953D65000C2B00 /* CertificateInfoBase.h in Headers */,
+                               FE36FD1516C7826500F887C1 /* ChangeVersionData.h in Headers */,
                                97BC69DD1505F076001B74AC /* ChangeVersionWrapper.h in Headers */,
                                FD315FFF12B0267600C1A359 /* ChannelMergerNode.h in Headers */,
                                FD31600212B0267600C1A359 /* ChannelSplitterNode.h in Headers */,
                                A12538D413F9B60A00024754 /* LayoutRepainter.h in Headers */,
                                11310CF320BA4A370065A8D0 /* LayoutReplaced.h in Headers */,
                                141DC054164834B900371E5A /* LayoutSize.h in Headers */,
-                               2D9066070BE141D400956998 /* LayoutState.h in Headers */,
+                               2D9066070BE141D400956998 /* RenderLayoutState.h in Headers */,
                                11310CF220BA4A320065A8D0 /* LayoutTreeBuilder.h in Headers */,
                                141DC0481648348F00371E5A /* LayoutUnit.h in Headers */,
                                CDE8B5ED1A69777300B4B66A /* LegacyCDMPrivateClearKey.h in Headers */,
index 0484031..1119dc3 100644 (file)
@@ -32,9 +32,9 @@
 #include "FrameView.h"
 #include "InspectorInstrumentation.h"
 #include "LayoutDisallowedScope.h"
-#include "LayoutState.h"
 #include "Logging.h"
 #include "RenderElement.h"
+#include "RenderLayoutState.h"
 #include "RenderView.h"
 #include "RuntimeEnabledFeatures.h"
 #include "ScriptDisallowedScope.h"
@@ -584,7 +584,7 @@ bool FrameViewLayoutContext::layoutDeltaMatches(const LayoutSize& delta)
 }
 #endif
 
-LayoutState* FrameViewLayoutContext::layoutState() const
+RenderLayoutState* FrameViewLayoutContext::layoutState() const
 {
     if (m_layoutStateStack.isEmpty())
         return nullptr;
@@ -596,14 +596,14 @@ void FrameViewLayoutContext::pushLayoutState(RenderElement& root)
     ASSERT(!m_paintOffsetCacheDisableCount);
     ASSERT(!layoutState());
 
-    m_layoutStateStack.append(std::make_unique<LayoutState>(root));
+    m_layoutStateStack.append(std::make_unique<RenderLayoutState>(root));
 }
 
 bool FrameViewLayoutContext::pushLayoutStateForPaginationIfNeeded(RenderBlockFlow& layoutRoot)
 {
     if (layoutState())
         return false;
-    m_layoutStateStack.append(std::make_unique<LayoutState>(layoutRoot, LayoutState::IsPaginated::Yes));
+    m_layoutStateStack.append(std::make_unique<RenderLayoutState>(layoutRoot, RenderLayoutState::IsPaginated::Yes));
     return true;
 }
     
@@ -613,7 +613,7 @@ bool FrameViewLayoutContext::pushLayoutState(RenderBox& renderer, const LayoutSi
     auto* layoutState = this->layoutState();
     if (!layoutState || !needsFullRepaint() || layoutState->isPaginated() || renderer.enclosingFragmentedFlow()
         || layoutState->lineGrid() || (renderer.style().lineGrid() != RenderStyle::initialLineGrid() && renderer.isRenderBlockFlow())) {
-        m_layoutStateStack.append(std::make_unique<LayoutState>(m_layoutStateStack, renderer, offset, pageHeight, pageHeightChanged));
+        m_layoutStateStack.append(std::make_unique<RenderLayoutState>(m_layoutStateStack, renderer, offset, pageHeight, pageHeightChanged));
         return true;
     }
     return false;
index 9d0ddbd..b07cf5a 100644 (file)
@@ -37,11 +37,11 @@ class Frame;
 class FrameView;
 class LayoutScope;
 class LayoutSize;
-class LayoutState;
 class RenderBlockFlow;
 class RenderBox;
 class RenderObject;
 class RenderElement;
+class RenderLayoutState;
 class RenderView;
     
 class FrameViewLayoutContext {
@@ -93,7 +93,7 @@ public:
 
     void flushAsynchronousTasks();
 
-    LayoutState* layoutState() const;
+    RenderLayoutState* layoutState() const;
     // Returns true if layoutState should be used for its cached offset and clip.
     bool isPaintOffsetCacheEnabled() const { return !m_paintOffsetCacheDisableCount && layoutState(); }
 #ifndef NDEBUG
@@ -107,7 +107,7 @@ public:
 #if !ASSERT_DISABLED
     bool layoutDeltaMatches(const LayoutSize& delta);
 #endif
-    using LayoutStateStack = Vector<std::unique_ptr<LayoutState>>;
+    using LayoutStateStack = Vector<std::unique_ptr<RenderLayoutState>>;
 
 private:
     friend class LayoutScope;
index f69b8c3..547299e 100644 (file)
@@ -55,6 +55,7 @@
 #include "RenderInline.h"
 #include "RenderIterator.h"
 #include "RenderLayer.h"
+#include "RenderLayoutState.h"
 #include "RenderListMarker.h"
 #include "RenderMenuList.h"
 #include "RenderSVGResourceClipper.h"
index b2e9bac..f266708 100644 (file)
@@ -31,7 +31,6 @@
 
 namespace WebCore {
 
-class LayoutState;
 class LineLayoutState;
 class LogicalSelectionOffsetCaches;
 class RenderInline;
index 6997970..2df8068 100644 (file)
 #include "HitTestLocation.h"
 #include "InlineTextBox.h"
 #include "LayoutRepainter.h"
-#include "LayoutState.h"
 #include "Logging.h"
 #include "RenderCombineText.h"
 #include "RenderFlexibleBox.h"
 #include "RenderInline.h"
 #include "RenderIterator.h"
 #include "RenderLayer.h"
+#include "RenderLayoutState.h"
 #include "RenderLineBreak.h"
 #include "RenderListItem.h"
 #include "RenderMarquee.h"
@@ -3842,7 +3842,7 @@ void RenderBlockFlow::checkForPaginationLogicalHeightChange(bool& relayoutChildr
         RenderFragmentedFlow& fragmentedFlow = downcast<RenderFragmentedFlow>(*this);
 
         // FIXME: This is a hack to always make sure we have a page logical height, if said height
-        // is known. The page logical height thing in LayoutState is meaningless for flow
+        // is known. The page logical height thing in RenderLayoutState is meaningless for flow
         // thread-based pagination (page height isn't necessarily uniform throughout the flow
         // thread), but as long as it is used universally as a means to determine whether page
         // height is known or not, we need this. Page height is unknown when column balancing is
index cba1c61..982fc38 100644 (file)
 #include "InlineIterator.h"
 #include "InlineTextBox.h"
 #include "InlineTextBoxStyle.h"
-#include "LayoutState.h"
 #include "LineLayoutState.h"
 #include "Logging.h"
 #include "RenderBlockFlow.h"
 #include "RenderFragmentContainer.h"
 #include "RenderFragmentedFlow.h"
+#include "RenderLayoutState.h"
 #include "RenderLineBreak.h"
 #include "RenderRubyBase.h"
 #include "RenderRubyText.h"
index bf88bd5..c0f3ff0 100644 (file)
@@ -47,7 +47,6 @@
 #include "HTMLTextAreaElement.h"
 #include "HitTestResult.h"
 #include "InlineElementBox.h"
-#include "LayoutState.h"
 #include "Page.h"
 #include "PaintInfo.h"
 #include "RenderBoxFragmentInfo.h"
@@ -61,6 +60,7 @@
 #include "RenderIterator.h"
 #include "RenderLayer.h"
 #include "RenderLayerCompositor.h"
+#include "RenderLayoutState.h"
 #include "RenderMultiColumnFlow.h"
 #include "RenderTableCell.h"
 #include "RenderTheme.h"
index 2c9192b..d537830 100644 (file)
@@ -42,7 +42,6 @@
 #include "HTMLParamElement.h"
 #include "HTMLPlugInElement.h"
 #include "HitTestResult.h"
-#include "LayoutState.h"
 #include "LocalizedStrings.h"
 #include "MouseEvent.h"
 #include "Page.h"
@@ -50,6 +49,7 @@
 #include "Path.h"
 #include "PlatformMouseEvent.h"
 #include "PluginViewBase.h"
+#include "RenderLayoutState.h"
 #include "RenderTheme.h"
 #include "RenderView.h"
 #include "Settings.h"
index 941da4f..44f5635 100644 (file)
@@ -33,7 +33,6 @@
 #include "HitTestRequest.h"
 #include "HitTestResult.h"
 #include "InlineElementBox.h"
-#include "LayoutState.h"
 #include "Node.h"
 #include "PODIntervalTree.h"
 #include "RenderBoxFragmentInfo.h"
@@ -41,6 +40,7 @@
 #include "RenderInline.h"
 #include "RenderLayer.h"
 #include "RenderLayerCompositor.h"
+#include "RenderLayoutState.h"
 #include "RenderTableCell.h"
 #include "RenderTableSection.h"
 #include "RenderTheme.h"
index 35acb00..ef45ce1 100644 (file)
@@ -32,9 +32,9 @@
 #include "GridPositionsResolver.h"
 #include "GridTrackSizingAlgorithm.h"
 #include "LayoutRepainter.h"
-#include "LayoutState.h"
 #include "RenderChildIterator.h"
 #include "RenderLayer.h"
+#include "RenderLayoutState.h"
 #include "RenderTreeBuilder.h"
 #include "RenderView.h"
 #include <cstdlib>
index 0572bfa..44a6e0e 100644 (file)
 #include "HTMLNames.h"
 #include "HitTestResult.h"
 #include "InlineElementBox.h"
-#include "LayoutState.h"
 #include "Page.h"
 #include "PaintInfo.h"
 #include "RenderFragmentedFlow.h"
 #include "RenderImageResourceStyleImage.h"
+#include "RenderLayoutState.h"
 #include "RenderTheme.h"
 #include "RenderView.h"
 #include "RuntimeEnabledFeatures.h"
index 5a95fb1..9c1b9c5 100644 (file)
@@ -30,7 +30,6 @@
 #include "HitTestResult.h"
 #include "InlineElementBox.h"
 #include "InlineTextBox.h"
-#include "LayoutState.h"
 #include "RenderBlock.h"
 #include "RenderChildIterator.h"
 #include "RenderFragmentedFlow.h"
@@ -38,6 +37,7 @@
 #include "RenderGeometryMap.h"
 #include "RenderIterator.h"
 #include "RenderLayer.h"
+#include "RenderLayoutState.h"
 #include "RenderLineBreak.h"
 #include "RenderListMarker.h"
 #include "RenderTable.h"
similarity index 91%
rename from Source/WebCore/rendering/LayoutState.cpp
rename to Source/WebCore/rendering/RenderLayoutState.cpp
index 879022e..0492c72 100644 (file)
@@ -24,7 +24,7 @@
  */
 
 #include "config.h"
-#include "LayoutState.h"
+#include "RenderLayoutState.h"
 
 #include "RenderFragmentedFlow.h"
 #include "RenderInline.h"
@@ -35,7 +35,7 @@
 
 namespace WebCore {
 
-LayoutState::LayoutState(RenderElement& renderer, IsPaginated isPaginated)
+RenderLayoutState::RenderLayoutState(RenderElement& renderer, IsPaginated isPaginated)
     : m_clipped(false)
     , m_isPaginated(isPaginated == IsPaginated::Yes)
     , m_pageLogicalHeightChanged(false)
@@ -64,7 +64,7 @@ LayoutState::LayoutState(RenderElement& renderer, IsPaginated isPaginated)
     }
 }
 
-LayoutState::LayoutState(const FrameViewLayoutContext::LayoutStateStack& layoutStateStack, RenderBox& renderer, const LayoutSize& offset, LayoutUnit pageLogicalHeight, bool pageLogicalHeightChanged)
+RenderLayoutState::RenderLayoutState(const FrameViewLayoutContext::LayoutStateStack& layoutStateStack, RenderBox& renderer, const LayoutSize& offset, LayoutUnit pageLogicalHeight, bool pageLogicalHeightChanged)
     : m_clipped(false)
     , m_isPaginated(false)
     , m_pageLogicalHeightChanged(false)
@@ -84,7 +84,7 @@ LayoutState::LayoutState(const FrameViewLayoutContext::LayoutStateStack& layoutS
     computePaginationInformation(layoutStateStack, renderer, pageLogicalHeight, pageLogicalHeightChanged);
 }
 
-void LayoutState::computeOffsets(const LayoutState& ancestor, RenderBox& renderer, LayoutSize offset)
+void RenderLayoutState::computeOffsets(const RenderLayoutState& ancestor, RenderBox& renderer, LayoutSize offset)
 {
     bool fixed = renderer.isFixedPositioned();
     if (fixed) {
@@ -115,7 +115,7 @@ void LayoutState::computeOffsets(const LayoutState& ancestor, RenderBox& rendere
 #endif
 }
 
-void LayoutState::computeClipRect(const LayoutState& ancestor, RenderBox& renderer)
+void RenderLayoutState::computeClipRect(const RenderLayoutState& ancestor, RenderBox& renderer)
 {
     m_clipped = !renderer.isFixedPositioned() && ancestor.isClipped();
     if (m_clipped)
@@ -133,7 +133,7 @@ void LayoutState::computeClipRect(const LayoutState& ancestor, RenderBox& render
     // FIXME: <http://bugs.webkit.org/show_bug.cgi?id=13443> Apply control clip if present.
 }
 
-void LayoutState::computePaginationInformation(const FrameViewLayoutContext::LayoutStateStack& layoutStateStack, RenderBox& renderer, LayoutUnit pageLogicalHeight, bool pageLogicalHeightChanged)
+void RenderLayoutState::computePaginationInformation(const FrameViewLayoutContext::LayoutStateStack& layoutStateStack, RenderBox& renderer, LayoutUnit pageLogicalHeight, bool pageLogicalHeightChanged)
 {
     auto* ancestor = layoutStateStack.isEmpty() ? nullptr : layoutStateStack.last().get();
     // If we establish a new page height, then cache the offset to the top of the first page.
@@ -170,14 +170,14 @@ void LayoutState::computePaginationInformation(const FrameViewLayoutContext::Lay
         establishLineGrid(layoutStateStack, downcast<RenderBlockFlow>(renderer));
 }
 
-LayoutUnit LayoutState::pageLogicalOffset(RenderBox* child, LayoutUnit childLogicalOffset) const
+LayoutUnit RenderLayoutState::pageLogicalOffset(RenderBox* child, LayoutUnit childLogicalOffset) const
 {
     if (child->isHorizontalWritingMode())
         return m_layoutOffset.height() + childLogicalOffset - m_pageOffset.height();
     return m_layoutOffset.width() + childLogicalOffset - m_pageOffset.width();
 }
 
-void LayoutState::computeLineGridPaginationOrigin(const RenderMultiColumnFlow& multicol)
+void RenderLayoutState::computeLineGridPaginationOrigin(const RenderMultiColumnFlow& multicol)
 {
     if (!isPaginated() || !pageLogicalHeight())
         return;
@@ -218,7 +218,7 @@ void LayoutState::computeLineGridPaginationOrigin(const RenderMultiColumnFlow& m
         m_lineGridPaginationOrigin.setWidth(paginationDelta);
 }
 
-void LayoutState::propagateLineGridInfo(const LayoutState& ancestor, RenderBox& renderer)
+void RenderLayoutState::propagateLineGridInfo(const RenderLayoutState& ancestor, RenderBox& renderer)
 {
     // Disable line grids for objects we don't support. For now this includes overflow:scroll/auto, inline blocks and
     // writing mode roots.
@@ -230,7 +230,7 @@ void LayoutState::propagateLineGridInfo(const LayoutState& ancestor, RenderBox&
     m_lineGridPaginationOrigin = ancestor.lineGridPaginationOrigin();
 }
 
-void LayoutState::establishLineGrid(const FrameViewLayoutContext::LayoutStateStack& layoutStateStack, RenderBlockFlow& renderer)
+void RenderLayoutState::establishLineGrid(const FrameViewLayoutContext::LayoutStateStack& layoutStateStack, RenderBlockFlow& renderer)
 {
     // First check to see if this grid has been established already.
     if (m_lineGrid) {
@@ -257,7 +257,7 @@ void LayoutState::establishLineGrid(const FrameViewLayoutContext::LayoutStateSta
     m_lineGridOffset = m_layoutOffset;
 }
 
-void LayoutState::addLayoutDelta(LayoutSize delta)
+void RenderLayoutState::addLayoutDelta(LayoutSize delta)
 {
     m_layoutDelta += delta;
 #if !ASSERT_DISABLED
@@ -267,7 +267,7 @@ void LayoutState::addLayoutDelta(LayoutSize delta)
 }
 
 #if !ASSERT_DISABLED
-bool LayoutState::layoutDeltaMatches(LayoutSize delta) const
+bool RenderLayoutState::layoutDeltaMatches(LayoutSize delta) const
 {
     return (delta.width() == m_layoutDelta.width() || m_layoutDeltaXSaturated) && (delta.height() == m_layoutDelta.height() || m_layoutDeltaYSaturated);
 }
similarity index 91%
rename from Source/WebCore/rendering/LayoutState.h
rename to Source/WebCore/rendering/RenderLayoutState.h
index 8ec3603..733a51f 100644 (file)
@@ -38,11 +38,11 @@ class RenderFragmentedFlow;
 class RenderMultiColumnFlow;
 class RenderObject;
 
-class LayoutState {
-    WTF_MAKE_NONCOPYABLE(LayoutState); WTF_MAKE_FAST_ALLOCATED;
+class RenderLayoutState {
+    WTF_MAKE_NONCOPYABLE(RenderLayoutState); WTF_MAKE_FAST_ALLOCATED;
 
 public:
-    LayoutState()
+    RenderLayoutState()
         : m_clipped(false)
         , m_isPaginated(false)
         , m_pageLogicalHeightChanged(false)
@@ -52,9 +52,9 @@ public:
 #endif
     {
     }
-    LayoutState(const FrameViewLayoutContext::LayoutStateStack&, RenderBox&, const LayoutSize& offset, LayoutUnit pageHeight, bool pageHeightChanged);
+    RenderLayoutState(const FrameViewLayoutContext::LayoutStateStack&, RenderBox&, const LayoutSize& offset, LayoutUnit pageHeight, bool pageHeightChanged);
     enum class IsPaginated { No, Yes };
-    explicit LayoutState(RenderElement&, IsPaginated = IsPaginated::No);
+    explicit RenderLayoutState(RenderElement&, IsPaginated = IsPaginated::No);
 
     bool isPaginated() const { return m_isPaginated; }
 
@@ -89,11 +89,11 @@ public:
 #endif
 
 private:
-    void computeOffsets(const LayoutState& ancestor, RenderBox&, LayoutSize offset);
-    void computeClipRect(const LayoutState& ancestor, RenderBox&);
+    void computeOffsets(const RenderLayoutState& ancestor, RenderBox&, LayoutSize offset);
+    void computeClipRect(const RenderLayoutState& ancestor, RenderBox&);
     // FIXME: webkit.org/b/179440 these functions should be part of the pagination code/FrameViewLayoutContext.
     void computePaginationInformation(const FrameViewLayoutContext::LayoutStateStack&, RenderBox&, LayoutUnit pageLogicalHeight, bool pageLogicalHeightChanged);
-    void propagateLineGridInfo(const LayoutState& ancestor, RenderBox&);
+    void propagateLineGridInfo(const RenderLayoutState& ancestor, RenderBox&);
     void establishLineGrid(const FrameViewLayoutContext::LayoutStateStack&, RenderBlockFlow&);
     void computeLineGridPaginationOrigin(const RenderMultiColumnFlow&);
 
index 5200813..cf7f2b9 100644 (file)
 #include "HTMLOptGroupElement.h"
 #include "HTMLSelectElement.h"
 #include "HitTestResult.h"
-#include "LayoutState.h"
 #include "NodeRenderStyle.h"
 #include "Page.h"
 #include "PaintInfo.h"
 #include "RenderLayer.h"
+#include "RenderLayoutState.h"
 #include "RenderScrollbar.h"
 #include "RenderText.h"
 #include "RenderTheme.h"
index c29a83a..53cd6cd 100644 (file)
@@ -30,8 +30,8 @@
 #if ENABLE(VIDEO)
 #include "RenderMediaControlElements.h"
 
-#include "LayoutState.h"
 #include "MediaControlElements.h"
+#include "RenderLayoutState.h"
 #include "RenderTheme.h"
 #include "RenderView.h"
 #include <wtf/IsoMallocInlines.h>
index 0cf7a36..06e3c3c 100644 (file)
@@ -27,8 +27,8 @@
 #include "RenderMultiColumnFlow.h"
 
 #include "HitTestResult.h"
-#include "LayoutState.h"
 #include "RenderIterator.h"
+#include "RenderLayoutState.h"
 #include "RenderMultiColumnSet.h"
 #include "RenderMultiColumnSpannerPlaceholder.h"
 #include "RenderTreeBuilder.h"
index 94e566b..d114a91 100644 (file)
 #include "HTMLNames.h"
 #include "HTMLTableElement.h"
 #include "LayoutRepainter.h"
-#include "LayoutState.h"
 #include "RenderBlockFlow.h"
 #include "RenderChildIterator.h"
 #include "RenderDescendantIterator.h"
 #include "RenderIterator.h"
 #include "RenderLayer.h"
+#include "RenderLayoutState.h"
 #include "RenderTableCaption.h"
 #include "RenderTableCell.h"
 #include "RenderTableCol.h"
index 3c67936..02d03ea 100644 (file)
@@ -28,8 +28,8 @@
 #include "Document.h"
 #include "HTMLNames.h"
 #include "HitTestResult.h"
-#include "LayoutState.h"
 #include "PaintInfo.h"
+#include "RenderLayoutState.h"
 #include "RenderTableCell.h"
 #include "RenderTreeBuilder.h"
 #include "RenderView.h"
index 6655d82..b623c90 100644 (file)
@@ -28,9 +28,9 @@
 #include "Document.h"
 #include "HitTestResult.h"
 #include "HTMLNames.h"
-#include "LayoutState.h"
 #include "PaintInfo.h"
 #include "RenderChildIterator.h"
+#include "RenderLayoutState.h"
 #include "RenderTableCell.h"
 #include "RenderTableCol.h"
 #include "RenderTableRow.h"
index cc056c9..6d69d16 100644 (file)
@@ -29,8 +29,8 @@
 #if ENABLE(VIDEO_TRACK)
 #include "RenderVTTCue.h"
 
-#include "LayoutState.h"
 #include "RenderInline.h"
+#include "RenderLayoutState.h"
 #include "RenderView.h"
 #include "TextTrackCueGeneric.h"
 #include "VTTCue.h"
index df479fc..d2535c4 100644 (file)
@@ -34,7 +34,6 @@
 #include "HTMLIFrameElement.h"
 #include "HitTestResult.h"
 #include "ImageQualityController.h"
-#include "LayoutState.h"
 #include "NodeTraversal.h"
 #include "Page.h"
 #include "RenderDescendantIterator.h"
@@ -43,6 +42,7 @@
 #include "RenderLayer.h"
 #include "RenderLayerBacking.h"
 #include "RenderLayerCompositor.h"
+#include "RenderLayoutState.h"
 #include "RenderMultiColumnFlow.h"
 #include "RenderMultiColumnSet.h"
 #include "RenderMultiColumnSpannerPlaceholder.h"
index 6cb8f31..8f17d36 100644 (file)
@@ -33,8 +33,8 @@
 namespace WebCore {
 
 class ImageQualityController;
-class LayoutState;
 class RenderLayerCompositor;
+class RenderLayoutState;
 class RenderQuote;
 
 class RenderView final : public RenderBlockFlow {
@@ -210,7 +210,7 @@ private:
     bool shouldRepaint(const LayoutRect&) const;
     void flushAccumulatedRepaintRegion() const;
 
-    void layoutContent(const LayoutState&);
+    void layoutContent(const RenderLayoutState&);
 
     bool isScrollableOrRubberbandableBox() const override;
 
index 3f809eb..aced278 100644 (file)
 #include "GraphicsContext.h"
 #include "HitTestResult.h"
 #include "InlineTextBox.h"
-#include "LayoutState.h"
 #include "LogicalSelectionOffsetCaches.h"
 #include "PaintInfo.h"
 #include "RenderFragmentedFlow.h"
 #include "RenderInline.h"
+#include "RenderLayoutState.h"
 #include "RenderRubyBase.h"
 #include "RenderRubyRun.h"
 #include "RenderRubyText.h"
index b86f5e5..e632006 100644 (file)
 #include "GraphicsContext.h"
 #include "HitTestResult.h"
 #include "LayoutRepainter.h"
-#include "LayoutState.h"
 #include "Page.h"
 #include "RenderIterator.h"
 #include "RenderLayer.h"
+#include "RenderLayoutState.h"
 #include "RenderSVGResource.h"
 #include "RenderSVGResourceContainer.h"
 #include "RenderSVGResourceFilter.h"
@@ -145,7 +145,7 @@ void RenderSVGRoot::layout()
 
     m_resourcesNeedingToInvalidateClients.clear();
 
-    // Arbitrary affine transforms are incompatible with LayoutState.
+    // Arbitrary affine transforms are incompatible with RenderLayoutState.
     LayoutStateDisabler layoutStateDisabler(view().frameView().layoutContext());
 
     bool needsLayout = selfNeedsLayout();