Commit eca7a455 authored by ajith.v's avatar ajith.v Committed by Commit bot

Correcting the usage of returning Size object

For returning Size params, we don't have to create a Rect
object. Instead returning Size value directly.

BUG=

Review-Url: https://codereview.chromium.org/2045443002
Cr-Commit-Position: refs/heads/master@{#398240}
parent b2235ba1
......@@ -608,9 +608,9 @@ gfx::Rect RenderWidgetHostViewAndroid::GetViewBounds() const {
gfx::Size RenderWidgetHostViewAndroid::GetVisibleViewportSize() const {
if (!content_view_core_)
return gfx::Rect(default_size_).size();
return default_size_;
return gfx::Rect(content_view_core_->GetViewSize()).size();
return content_view_core_->GetViewSize();
}
gfx::Size RenderWidgetHostViewAndroid::GetPhysicalBackingSize() const {
......@@ -621,12 +621,10 @@ gfx::Size RenderWidgetHostViewAndroid::GetPhysicalBackingSize() const {
}
bool RenderWidgetHostViewAndroid::DoTopControlsShrinkBlinkSize() const {
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_->DoTopControlsShrinkBlinkSize();
return content_view_core_ &&
content_view_core_->DoTopControlsShrinkBlinkSize();
}
float RenderWidgetHostViewAndroid::GetTopControlsHeight() const {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment