Changeset 223590 in webkit
- Timestamp:
- Oct 17, 2017 6:42:26 PM (7 years ago)
- Location:
- trunk/Source/WebCore
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r223589 r223590 1 2017-10-17 Zalan Bujtas <zalan@apple.com> 2 3 [FrameView::layout cleanup] Remove redundant body->renderer()->setChildNeedsLayout() call 4 https://bugs.webkit.org/show_bug.cgi?id=178414 5 <rdar://problem/35040876> 6 7 Reviewed by Simon Fraser. 8 9 Since m_size always equals to layoutSize() at this point, we never call setChildNeedsLayout() on the body's renderer. 10 However a few lines below, when we adjust the frame size and check if oldSize != m_size, we actually 11 dirty the body's renderer. 12 13 Covered by existing tests. 14 15 * page/FrameView.cpp: 16 (WebCore::FrameView::layout): 17 1 18 2017-10-17 Myles C. Maxfield <mmaxfield@apple.com> 2 19 -
trunk/Source/WebCore/page/FrameView.cpp
r223569 r223590 1434 1434 return; 1435 1435 isSubtreeLayout = m_subtreeLayoutRoot; 1436 m_needsFullRepaint = !isSubtreeLayout && (m_firstLayout || downcast<RenderView>(*layoutRoot).printing()); 1436 1437 1437 1438 if (!isSubtreeLayout) { 1438 auto* body = document.bodyOrFrameset(); 1439 if (body && body->renderer()) { 1440 if (is<HTMLFrameSetElement>(*body) && !frameFlatteningEnabled()) { 1439 if (auto* body = document.bodyOrFrameset()) { 1440 if (is<HTMLFrameSetElement>(*body) && !frameFlatteningEnabled() && body->renderer()) 1441 1441 body->renderer()->setChildNeedsLayout(); 1442 } else if (is<HTMLBodyElement>(*body)) {1443 if (!m_firstLayout && m_size.height() != layoutHeight() && body->renderer()->enclosingBox().stretchesToViewport())1444 body->renderer()->setChildNeedsLayout();1445 }1446 1442 } 1447 1448 1443 #if !LOG_DISABLED 1449 1444 if (m_firstLayout && !frame().ownerElement()) 1450 1445 LOG(Layout, "FrameView %p elapsed time before first layout: %.3fs\n", this, document.timeSinceDocumentCreation().value()); 1451 1446 #endif 1452 }1453 1454 m_needsFullRepaint = !isSubtreeLayout && (m_firstLayout || downcast<RenderView>(*layoutRoot).printing());1455 1456 if (!isSubtreeLayout) {1457 1447 ScrollbarMode hMode; 1458 1448 ScrollbarMode vMode;
Note: See TracChangeset
for help on using the changeset viewer.