| Index: third_party/WebKit/Source/core/page/Page.cpp
|
| diff --git a/third_party/WebKit/Source/core/page/Page.cpp b/third_party/WebKit/Source/core/page/Page.cpp
|
| index fe3e99ea8e0f9a28f94f496c9aba209c8ad98917..a5fa749cea263a6e18c4c61f819f0e9c28fef445 100644
|
| --- a/third_party/WebKit/Source/core/page/Page.cpp
|
| +++ b/third_party/WebKit/Source/core/page/Page.cpp
|
| @@ -436,6 +436,11 @@ void Page::didCommitLoad(LocalFrame* frame)
|
| useCounter().didCommitLoad();
|
| deprecation().clearSuppression();
|
| frameHost().visualViewport().sendUMAMetrics();
|
| +
|
| + // Need to reset visual viewport position here since before commit load we would update the previous history item,
|
| + // Page::didCommitLoad is called after a new history item is created in FrameLoader.
|
| + // fix for crbug.com/642279
|
| + frameHost().visualViewport().setScrollPosition(DoublePoint(), ProgrammaticScroll);
|
| m_hostsUsingFeatures.updateMeasurementsAndClear();
|
| UserGestureIndicator::clearProcessedUserGestureSinceLoad();
|
| }
|
|
|