Index: third_party/WebKit/Source/core/frame/FrameView.cpp |
diff --git a/third_party/WebKit/Source/core/frame/FrameView.cpp b/third_party/WebKit/Source/core/frame/FrameView.cpp |
index 2cfd1d97e78a89a94c185f8208f98788d830eb23..7b44afa35b6f956d07c673b4d628d4c53d42e63f 100644 |
--- a/third_party/WebKit/Source/core/frame/FrameView.cpp |
+++ b/third_party/WebKit/Source/core/frame/FrameView.cpp |
@@ -3107,44 +3107,40 @@ void FrameView::UpdateLifecyclePhasesInternal( |
}); |
} |
- if (target_state == DocumentLifecycle::kCompositingInputsClean) { |
- DCHECK_EQ(Lifecycle().GetState(), |
- DocumentLifecycle::kCompositingInputsClean); |
- return; |
- } |
- |
- ScrollContentsIfNeededRecursive(); |
- DCHECK(RuntimeEnabledFeatures::slimmingPaintInvalidationEnabled() || |
- Lifecycle().GetState() >= DocumentLifecycle::kCompositingClean); |
- |
- frame_->GetPage()->GlobalRootScrollerController().DidUpdateCompositing(); |
- |
- if (target_state >= DocumentLifecycle::kPrePaintClean) { |
- if (!RuntimeEnabledFeatures::slimmingPaintInvalidationEnabled()) |
- InvalidateTreeIfNeededRecursive(); |
- |
- if (!RuntimeEnabledFeatures::slimmingPaintV2Enabled()) { |
- if (view.Compositor()->InCompositingMode()) |
- GetScrollingCoordinator()->UpdateAfterCompositingChangeIfNeeded(); |
+ if (target_state >= DocumentLifecycle::kCompositingClean) { |
+ ScrollContentsIfNeededRecursive(); |
+ |
+ frame_->GetPage() |
+ ->GlobalRootScrollerController() |
+ .DidUpdateCompositing(); |
+ |
+ if (target_state >= DocumentLifecycle::kPrePaintClean) { |
flackr
2017/04/28 19:38:18
Can we unnest this condition if there's no follow-
smcgruer
2017/04/28 19:43:44
Uh. Yes. I am silly.
|
+ if (!RuntimeEnabledFeatures::slimmingPaintInvalidationEnabled()) |
+ InvalidateTreeIfNeededRecursive(); |
+ |
+ if (!RuntimeEnabledFeatures::slimmingPaintV2Enabled()) { |
+ if (view.Compositor()->InCompositingMode()) |
+ GetScrollingCoordinator()->UpdateAfterCompositingChangeIfNeeded(); |
+ } |
+ |
+ if (LocalFrame* local_frame = frame_->LocalFrameRoot()) { |
+ // This is needed since, at present, the ScrollingCoordinator |
+ // doesn't send rects for oopif sub-frames. |
+ // TODO(wjmaclean): Remove this pathway when ScrollingCoordinator |
+ // operates on a per-frame basis. https://crbug.com/680606 |
+ GetFrame() |
+ .GetPage() |
+ ->GetChromeClient() |
+ .UpdateEventRectsForSubframeIfNecessary(local_frame); |
+ } |
+ UpdateCompositedSelectionIfNeeded(); |
} |
- if (LocalFrame* local_frame = frame_->LocalFrameRoot()) { |
- // This is needed since, at present, the ScrollingCoordinator doesn't |
- // send rects for oopif sub-frames. |
- // TODO(wjmaclean): Remove this pathway when ScrollingCoordinator |
- // operates on a per-frame basis. https://crbug.com/680606 |
- GetFrame() |
- .GetPage() |
- ->GetChromeClient() |
- .UpdateEventRectsForSubframeIfNecessary(local_frame); |
- } |
- UpdateCompositedSelectionIfNeeded(); |
+ // TODO(pdr): prePaint should be under the "Paint" devtools timeline |
+ // step for slimming paint v2. |
+ if (target_state >= DocumentLifecycle::kPrePaintClean) |
flackr
2017/04/28 19:38:18
Unless my eyes deceive me, this is the identical c
smcgruer
2017/04/28 19:43:44
Done.
|
+ PrePaint(); |
} |
- |
- // TODO(pdr): prePaint should be under the "Paint" devtools timeline step |
- // for slimming paint v2. |
- if (target_state >= DocumentLifecycle::kPrePaintClean) |
- PrePaint(); |
} |
if (target_state == DocumentLifecycle::kPaintClean) { |