| 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 8ff445e12fb425194478fef4894e3037d6f85bb5..921b854f22b0037ef43cc99a0c105a8577fe9457 100644
|
| --- a/third_party/WebKit/Source/core/frame/FrameView.cpp
|
| +++ b/third_party/WebKit/Source/core/frame/FrameView.cpp
|
| @@ -814,13 +814,6 @@ void FrameView::performPreLayoutTasks()
|
| document->updateStyleAndLayoutTree();
|
| lifecycle().advanceTo(DocumentLifecycle::StyleClean);
|
|
|
| - if (m_frame->isMainFrame() && !m_viewportScrollableArea) {
|
| - ScrollableArea& visualViewport = m_frame->host()->visualViewport();
|
| - ScrollableArea* layoutViewport = layoutViewportScrollableArea();
|
| - ASSERT(layoutViewport);
|
| - m_viewportScrollableArea = RootFrameViewport::create(visualViewport, *layoutViewport);
|
| - }
|
| -
|
| if (RuntimeEnabledFeatures::scrollAnchoringEnabled())
|
| m_scrollAnchor.save();
|
| }
|
| @@ -2393,6 +2386,17 @@ void FrameView::updateDocumentAnnotatedRegions() const
|
| page->chromeClient().annotatedRegionsChanged();
|
| }
|
|
|
| +void FrameView::didAttachDocument()
|
| +{
|
| + if (m_frame->isMainFrame()) {
|
| + DCHECK(m_frame->host());
|
| + ScrollableArea& visualViewport = m_frame->host()->visualViewport();
|
| + ScrollableArea* layoutViewport = layoutViewportScrollableArea();
|
| + DCHECK(layoutViewport);
|
| + m_viewportScrollableArea = RootFrameViewport::create(visualViewport, *layoutViewport);
|
| + }
|
| +}
|
| +
|
| void FrameView::updateScrollCorner()
|
| {
|
| RefPtr<ComputedStyle> cornerStyle;
|
|
|