Changeset 252735 in webkit
- Timestamp:
- Nov 21, 2019 8:32:09 AM (4 years ago)
- Location:
- trunk/Source/WebCore
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r252732 r252735 1 2019-11-21 Zalan Bujtas <zalan@apple.com> 2 3 [LFC] Add support for LFC layout only. 4 https://bugs.webkit.org/show_bug.cgi?id=204441 5 <rdar://problem/57382929> 6 7 Reviewed by Antti Koivisto. 8 9 Clean up the render tree state when RenderView::layout is not called. 10 11 * page/FrameViewLayoutContext.cpp: 12 (WebCore::FrameViewLayoutContext::layoutUsingFormattingContext): 13 * rendering/updating/RenderTreeUpdater.cpp: 14 (WebCore::RenderTreeUpdater::updateRendererStyle): 15 1 16 2019-11-21 Andres Gonzalez <andresg_22@apple.com> 2 17 -
trunk/Source/WebCore/page/FrameViewLayoutContext.cpp
r252534 r252735 41 41 #include "Settings.h" 42 42 #if ENABLE(LAYOUT_FORMATTING_CONTEXT) 43 #include "DisplayBox.h" 43 44 #include "InvalidationContext.h" 44 45 #include "InvalidationState.h" … … 46 47 #include "LayoutState.h" 47 48 #include "LayoutTreeBuilder.h" 49 #include "RenderDescendantIterator.h" 48 50 #endif 49 51 … … 60 62 return; 61 63 64 auto& renderView = *this->renderView(); 62 65 if (!m_layoutTreeContent) { 63 m_layoutTreeContent = Layout::TreeBuilder::buildLayoutTree( *renderView());66 m_layoutTreeContent = Layout::TreeBuilder::buildLayoutTree(renderView); 64 67 // FIXME: New layout tree requires a new state for now. 65 68 m_layoutState = nullptr; … … 74 77 75 78 auto layoutContext = Layout::LayoutContext { *m_layoutState }; 76 layoutContext.layout(renderView()->size(), invalidationState); 79 layoutContext.layout(view().layoutSize(), invalidationState); 80 81 // Clean up the render tree state when we don't run RenderView::layout. 82 if (renderView.needsLayout()) { 83 auto contentSize = m_layoutState->displayBoxForLayoutBox(*m_layoutState->root().firstChild()).size(); 84 renderView.setSize(contentSize); 85 renderView.repaintViewRectangle({ 0, 0, contentSize.width(), contentSize.height() }); 86 87 for (auto& descendant : descendantsOfType<RenderObject>(renderView)) 88 descendant.clearNeedsLayout(); 89 renderView.clearNeedsLayout(); 90 } 91 77 92 #ifndef NDEBUG 78 93 Layout::LayoutContext::verifyAndOutputMismatchingLayoutTree(*m_layoutState); -
trunk/Source/WebCore/rendering/updating/RenderTreeUpdater.cpp
r252638 r252735 298 298 #if ENABLE(LAYOUT_FORMATTING_CONTEXT) 299 299 if (RuntimeEnabledFeatures::sharedFeatures().layoutFormattingContextEnabled()) { 300 if (!m_document.view() || !m_document.view()->layoutContext().layout FormattingState())300 if (!m_document.view() || !m_document.view()->layoutContext().layoutTreeContent()) 301 301 return; 302 302 if (auto* layoutBox = m_document.view()->layoutContext().layoutTreeContent()->layoutBoxForRenderer(renderer))
Note: See TracChangeset
for help on using the changeset viewer.