Index: Source/core/frame/FrameView.cpp |
diff --git a/Source/core/frame/FrameView.cpp b/Source/core/frame/FrameView.cpp |
index f4436bcd726cc5ca68e9c20cc3cb5432733488b1..ffa5288a2d7de0123ea58d025b57572d67267310 100644 |
--- a/Source/core/frame/FrameView.cpp |
+++ b/Source/core/frame/FrameView.cpp |
@@ -2453,22 +2453,28 @@ void FrameView::updateLifecycleToCompositingCleanPlusScrolling() |
void FrameView::updateAllLifecyclePhasesInternal() |
{ |
- // This must be called from the root frame, since it recurses down, not up. Otherwise the lifecycles of the frames might be out of sync. |
- ASSERT(frame() == page()->mainFrame() || (!frame().tree().parent()->isLocalFrame())); |
+ // This must be called from the root frame, since it recurses down, not up. |
+ // Otherwise the lifecycles of the frames might be out of sync. |
+ ASSERT(m_frame->isLocalRoot()); |
// Updating layout can run script, which can tear down the FrameView. |
RefPtrWillBeRawPtr<FrameView> protector(this); |
updateStyleAndLayoutIfNeededRecursive(); |
- LayoutView* view = layoutView(); |
- if (view) { |
+ if (LayoutView* view = layoutView()) { |
TRACE_EVENT1("devtools.timeline", "UpdateLayerTree", "data", InspectorUpdateLayerTreeEvent::data(m_frame.get())); |
view->compositor()->updateIfNeededRecursive(); |
scrollContentsIfNeededRecursive(); |
invalidateTreeIfNeededRecursive(); |
- updatePostLifecycleData(); |
+ |
+ if (view->compositor()->inCompositingMode()) |
+ scrollingCoordinator()->updateAfterCompositingChangeIfNeeded(); |
+ |
+ updateCompositedSelectionIfNeeded(); |
+ if (RuntimeEnabledFeatures::frameTimingSupportEnabled()) |
+ updateFrameTimingRequestsIfNeeded(); |
ASSERT(!view->hasPendingSelection()); |
} |
@@ -2476,19 +2482,6 @@ void FrameView::updateAllLifecyclePhasesInternal() |
ASSERT(lifecycle().state() == DocumentLifecycle::PaintInvalidationClean); |
} |
-void FrameView::updatePostLifecycleData() |
-{ |
- LayoutView* view = layoutView(); |
- ASSERT(view); |
- |
- if (view->compositor()->inCompositingMode() && m_frame->isLocalRoot()) |
- scrollingCoordinator()->updateAfterCompositingChangeIfNeeded(); |
- |
- updateCompositedSelectionIfNeeded(); |
- if (RuntimeEnabledFeatures::frameTimingSupportEnabled()) |
- updateFrameTimingRequestsIfNeeded(); |
-} |
- |
void FrameView::updateFrameTimingRequestsIfNeeded() |
{ |
GraphicsLayerFrameTimingRequests graphicsLayerTimingRequests; |