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

Unified Diff: content/browser/web_contents/web_contents_view_aura.cc

Issue 30683003: Remove final RenderWidgetHostImpl dependency from OverscrollController (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove explicit Created 7 years, 2 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
Index: content/browser/web_contents/web_contents_view_aura.cc
diff --git a/content/browser/web_contents/web_contents_view_aura.cc b/content/browser/web_contents/web_contents_view_aura.cc
index 2b33dab8b71c38a640e3abb36921cb0500faf3df..eab057d426b9e998f2717ed3a7b829214513a849 100644
--- a/content/browser/web_contents/web_contents_view_aura.cc
+++ b/content/browser/web_contents/web_contents_view_aura.cc
@@ -1357,6 +1357,14 @@ void WebContentsViewAura::TakeFocus(bool reverse) {
////////////////////////////////////////////////////////////////////////////////
// WebContentsViewAura, OverscrollControllerDelegate implementation:
+gfx::Rect WebContentsViewAura::GetVisibleBounds() const {
+ RenderWidgetHostView* rwhv = web_contents_->GetRenderWidgetHostView();
+ if (!rwhv || !rwhv->IsShowing())
+ return gfx::Rect();
+
+ return rwhv->GetViewBounds();
+}
+
void WebContentsViewAura::OnOverscrollUpdate(float delta_x, float delta_y) {
if (current_overscroll_gesture_ == OVERSCROLL_NONE)
return;

Powered by Google App Engine
This is Rietveld 408576698