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 5cfb85f3f5f5fddc20055ed245de877eeb10987f..3192a7a21100b96c6db25ec2b03234ab3d044413 100644 |
--- a/third_party/WebKit/Source/core/frame/FrameView.cpp |
+++ b/third_party/WebKit/Source/core/frame/FrameView.cpp |
@@ -431,8 +431,11 @@ void FrameView::setFrameRect(const IntRect& newRect) { |
viewportSizeChanged(newRect.width() != oldRect.width(), |
newRect.height() != oldRect.height()); |
- if (m_frame->isMainFrame()) |
+ if (m_frame->isMainFrame()) { |
m_frame->host()->visualViewport().mainFrameDidChangeSize(); |
+ if (Document* document = m_frame->document()) |
+ document->styleEngine().initialViewportChanged(); |
+ } |
frame().loader().restoreScrollPositionAndViewState(); |
} |
} |