Index: Source/web/tests/WebViewTest.cpp |
diff --git a/Source/web/tests/WebViewTest.cpp b/Source/web/tests/WebViewTest.cpp |
index 90408150d37e27ed7d3a9e6ec42d253cd2c734c9..59e4d9d7fb7b834c1ef7c3664a48f4b64ca38409 100644 |
--- a/Source/web/tests/WebViewTest.cpp |
+++ b/Source/web/tests/WebViewTest.cpp |
@@ -729,7 +729,7 @@ TEST_F(WebViewTest, HistoryResetScrollAndScaleState) |
EXPECT_EQ(2.0f, webViewImpl->pageScaleFactor()); |
EXPECT_EQ(116, webViewImpl->mainFrame()->scrollOffset().width); |
EXPECT_EQ(84, webViewImpl->mainFrame()->scrollOffset().height); |
- webViewImpl->page()->mainFrame()->loader().history()->saveDocumentAndScrollState(); |
+ webViewImpl->page()->history()->saveDocumentAndScrollState(webViewImpl->page()->mainFrame()); |
// Confirm that restoring the page state restores the parameters. |
webViewImpl->setPageScaleFactor(1.5f, WebPoint(16, 24)); |
@@ -740,11 +740,11 @@ TEST_F(WebViewTest, HistoryResetScrollAndScaleState) |
// wasScrolledByUser flag on the main frame, and prevent restoreScrollPositionAndViewState |
// from restoring the scrolling position. |
webViewImpl->page()->mainFrame()->view()->setWasScrolledByUser(false); |
- webViewImpl->page()->mainFrame()->loader().history()->restoreScrollPositionAndViewState(); |
+ webViewImpl->page()->history()->restoreScrollPositionAndViewState(webViewImpl->page()->mainFrame()); |
EXPECT_EQ(2.0f, webViewImpl->pageScaleFactor()); |
EXPECT_EQ(116, webViewImpl->mainFrame()->scrollOffset().width); |
EXPECT_EQ(84, webViewImpl->mainFrame()->scrollOffset().height); |
- webViewImpl->page()->mainFrame()->loader().history()->saveDocumentAndScrollState(); |
+ webViewImpl->page()->history()->saveDocumentAndScrollState(webViewImpl->page()->mainFrame()); |
// Confirm that resetting the page state resets the saved scroll position. |
// The HistoryController treats a page scale factor of 0.0f as special and avoids |
@@ -753,7 +753,7 @@ TEST_F(WebViewTest, HistoryResetScrollAndScaleState) |
EXPECT_EQ(1.0f, webViewImpl->pageScaleFactor()); |
EXPECT_EQ(0, webViewImpl->mainFrame()->scrollOffset().width); |
EXPECT_EQ(0, webViewImpl->mainFrame()->scrollOffset().height); |
- webViewImpl->page()->mainFrame()->loader().history()->restoreScrollPositionAndViewState(); |
+ webViewImpl->page()->history()->restoreScrollPositionAndViewState(webViewImpl->page()->mainFrame()); |
EXPECT_EQ(1.0f, webViewImpl->pageScaleFactor()); |
EXPECT_EQ(0, webViewImpl->mainFrame()->scrollOffset().width); |
EXPECT_EQ(0, webViewImpl->mainFrame()->scrollOffset().height); |