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

Unified Diff: content/browser/renderer_host/render_widget_host_view_android.cc

Issue 714003002: Allow changing top controls height (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed other test build breaks Created 6 years, 1 month 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
Index: content/browser/renderer_host/render_widget_host_view_android.cc
diff --git a/content/browser/renderer_host/render_widget_host_view_android.cc b/content/browser/renderer_host/render_widget_host_view_android.cc
index 95a77bec91e03dd03496e8d52fe427207f3f75a4..b9b7ac650be91a23531e3a5c96dccda80b860189 100644
--- a/content/browser/renderer_host/render_widget_host_view_android.cc
+++ b/content/browser/renderer_host/render_widget_host_view_android.cc
@@ -669,12 +669,21 @@ gfx::Size RenderWidgetHostViewAndroid::GetPhysicalBackingSize() const {
return content_view_core_->GetPhysicalBackingSize();
}
-float RenderWidgetHostViewAndroid::GetTopControlsLayoutHeight() const {
+bool RenderWidgetHostViewAndroid::GetTopControlsShrinkBlinkSize() const {
palmer 2014/12/01 19:57:54 The name |GetTopControlsShrinkBlinkSize| is really
David Trainor- moved to gerrit 2014/12/02 05:53:25 Yeah I can see that being a bit confusing. I coul
+ if (!content_view_core_)
+ return false;
+
+ // Whether or not Blink's viewport size should be shrunk by the height of the
+ // URL-bar.
+ return content_view_core_->GetTopControlsShrinkBlinkSize();
+}
+
+float RenderWidgetHostViewAndroid::GetTopControlsHeight() const {
if (!content_view_core_)
return 0.f;
- // The amount that the viewport size given to Blink is shrunk by the URL-bar.
- return content_view_core_->GetTopControlsLayoutHeightDip();
+ // The height of the top controls.
+ return content_view_core_->GetTopControlsHeightDip();
}
void RenderWidgetHostViewAndroid::UpdateCursor(const WebCursor& cursor) {

Powered by Google App Engine
This is Rietveld 408576698