Chromium Code Reviews| Index: third_party/WebKit/Source/web/WebViewImpl.cpp |
| diff --git a/third_party/WebKit/Source/web/WebViewImpl.cpp b/third_party/WebKit/Source/web/WebViewImpl.cpp |
| index b708684218ae54a865aeae4eeb2b26bc81067bdf..aaae12c8c6983414012c430a304fe752f3665f82 100644 |
| --- a/third_party/WebKit/Source/web/WebViewImpl.cpp |
| +++ b/third_party/WebKit/Source/web/WebViewImpl.cpp |
| @@ -3880,9 +3880,14 @@ void WebViewImpl::setSelectionColors(unsigned activeBackgroundColor, |
| void WebViewImpl::didCommitLoad(bool isNewNavigation, bool isNavigationWithinPage) |
| { |
| - if (isNewNavigation && !isNavigationWithinPage) { |
| - pageScaleConstraintsSet().setNeedsReset(true); |
| - m_pageImportanceSignals.onCommitLoad(); |
| + if (!isNavigationWithinPage) { |
| + m_shouldDispatchFirstVisuallyNonEmptyLayout = true; |
| + m_shouldDispatchFirstLayoutAfterFinishedParsing = true; |
| + |
| + if (isNewNavigation) { |
| + pageScaleConstraintsSet().setNeedsReset(true); |
| + m_pageImportanceSignals.onCommitLoad(); |
|
Alexander Semashko
2015/10/05 13:11:11
As a side question, do these two lines need to be
bokan
2015/10/05 18:03:30
I can only speak to the setNeedsReset on pageScale
|
| + } |
| } |
| // Give the visual viewport's scroll layer its initial size. |
| @@ -4163,8 +4168,6 @@ void WebViewImpl::setRootGraphicsLayer(GraphicsLayer* layer) |
| // attempt to paint too early in the next page load. |
| m_layerTreeView->setDeferCommits(true); |
| m_layerTreeView->clearRootLayer(); |
| - m_shouldDispatchFirstVisuallyNonEmptyLayout = true; |
| - m_shouldDispatchFirstLayoutAfterFinishedParsing = true; |
| page()->frameHost().visualViewport().clearLayersForTreeView(m_layerTreeView); |
| } |
| } |