Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(170)

Unified Diff: third_party/WebKit/Source/web/tests/WebFrameTest.cpp

Issue 1844013002: Fix main thread top controls scrolling to mirror CC. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@propertyTreesBoundsDelta
Patch Set: Build fix after rebase Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/WebKit/Source/web/tests/VisualViewportTest.cpp ('k') | third_party/WebKit/public/web/WebView.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/web/tests/WebFrameTest.cpp
diff --git a/third_party/WebKit/Source/web/tests/WebFrameTest.cpp b/third_party/WebKit/Source/web/tests/WebFrameTest.cpp
index e202ac973b5aecc98c82f255ebdc1531b40d4ece..5925f5b011049cce56fa2e49e0bbfa1d4f06668f 100644
--- a/third_party/WebKit/Source/web/tests/WebFrameTest.cpp
+++ b/third_party/WebKit/Source/web/tests/WebFrameTest.cpp
@@ -6420,8 +6420,7 @@ TEST_F(WebFrameTest, FrameViewScrollAccountsForTopControls)
FrameView* frameView = webViewHelper.webViewImpl()->mainFrameImpl()->frameView();
float topControlsHeight = 40;
- webView->setTopControlsHeight(topControlsHeight, false);
- webViewHelper.resize(WebSize(100, 100));
+ webView->resizeWithTopControls(WebSize(100, 100), topControlsHeight, false);
webView->setPageScaleFactor(2.0f);
webView->updateAllLifecyclePhases();
@@ -6446,8 +6445,7 @@ TEST_F(WebFrameTest, FrameViewScrollAccountsForTopControls)
// the top controls and Blink's view of the top controls matches that of
// the CC
webView->applyViewportDeltas(WebFloatSize(), WebFloatSize(), WebFloatSize(), 1.0f, 30.0f / topControlsHeight);
- webView->setTopControlsHeight(40.0f, true);
- webViewHelper.resize(WebSize(100, 60));
+ webView->resizeWithTopControls(WebSize(100, 60), 40.0f, true);
webView->updateAllLifecyclePhases();
EXPECT_POINT_EQ(IntPoint(0, 1940), frameView->maximumScrollPosition());
@@ -6457,8 +6455,7 @@ TEST_F(WebFrameTest, FrameViewScrollAccountsForTopControls)
// Reset to original state: 100px widget height, top controls fully hidden.
webView->applyViewportDeltas(WebFloatSize(), WebFloatSize(), WebFloatSize(), 1.0f, -30.0f / topControlsHeight);
- webView->setTopControlsHeight(topControlsHeight, false);
- webViewHelper.resize(WebSize(100, 100));
+ webView->resizeWithTopControls(WebSize(100, 100), topControlsHeight, false);
webView->updateAllLifecyclePhases();
EXPECT_POINT_EQ(IntPoint(0, 1900), frameView->maximumScrollPosition());
« no previous file with comments | « third_party/WebKit/Source/web/tests/VisualViewportTest.cpp ('k') | third_party/WebKit/public/web/WebView.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698