Chromium Code Reviews| 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 94b9738bcba2e46c73347ca92297c95115a7e7f8..6e771debaa47f48d904f16a12b6a0515928f1b12 100644 |
| --- a/third_party/WebKit/Source/core/frame/FrameView.cpp |
| +++ b/third_party/WebKit/Source/core/frame/FrameView.cpp |
| @@ -2816,6 +2816,10 @@ void FrameView::updateWidgetGeometriesIfNeeded() { |
| updateWidgetGeometries(); |
| } |
| +GeometryMapper* FrameView::geometryMapper() { |
| + return frame().localFrameRoot()->view()->m_geometryMapper.get(); |
|
pdr.
2017/02/10 20:51:04
Can you DCHECK here to prevent calling without sp?
chrishtr
2017/02/10 22:56:36
Done.
|
| +} |
| + |
| void FrameView::updateAllLifecyclePhases() { |
| frame().localFrameRoot()->view()->updateLifecyclePhasesInternal( |
| DocumentLifecycle::PaintClean); |
| @@ -2945,6 +2949,15 @@ void FrameView::updateLifecyclePhasesInternal( |
| TRACE_EVENT1("devtools.timeline", "UpdateLayerTree", "data", |
| InspectorUpdateLayerTreeEvent::data(m_frame.get())); |
| + if (RuntimeEnabledFeatures::slimmingPaintInvalidationEnabled()) { |
| + if (!m_geometryMapper) |
| + m_geometryMapper.reset(new GeometryMapper()); |
| + // TODO(chrishtr): the cache only needs to be invalidated if one or more |
| + // of |
|
pdr.
2017/02/10 20:51:03
nit: indentation
chrishtr
2017/02/10 22:56:36
Moved.
|
| + // the property tree nodes changed. |
| + m_geometryMapper->clearCache(); |
|
pdr.
2017/02/10 20:51:03
Can we assert that geometry mapper isn't used betw
chrishtr
2017/02/10 22:56:36
Done, via suggestion from above.
|
| + } |
| + |
| if (!RuntimeEnabledFeatures::slimmingPaintV2Enabled()) { |
| view.compositor()->updateIfNeededRecursive(); |
| } else { |
| @@ -3032,12 +3045,6 @@ void FrameView::prePaint() { |
| if (!m_paintController) |
| m_paintController = PaintController::create(); |
| - if (!m_geometryMapper) |
| - m_geometryMapper.reset(new GeometryMapper()); |
| - // TODO(chrishtr): the cache only needs to be invalidated if one or more of |
| - // the property tree nodes changed. |
| - m_geometryMapper->clearCache(); |
| - |
| forAllNonThrottledFrameViews([](FrameView& frameView) { |
| frameView.lifecycle().advanceTo(DocumentLifecycle::InPrePaint); |
| if (frameView.canThrottleRendering()) { |