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

Side by Side Diff: content/browser/web_contents/web_contents_view_android.cc

Issue 13688004: Location/size change notification when external rendering is enabled (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address Andrew's comments. Created 7 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/browser/web_contents/web_contents_view_android.h" 5 #include "content/browser/web_contents/web_contents_view_android.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "content/browser/android/content_view_core_impl.h" 8 #include "content/browser/android/content_view_core_impl.h"
9 #include "content/browser/android/media_player_manager_android.h" 9 #include "content/browser/android/media_player_manager_android.h"
10 #include "content/browser/renderer_host/render_widget_host_view_android.h" 10 #include "content/browser/renderer_host/render_widget_host_view_android.h"
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
52 if (rwhv) 52 if (rwhv)
53 rwhv->SetContentViewCore(content_view_core_); 53 rwhv->SetContentViewCore(content_view_core_);
54 } 54 }
55 } 55 }
56 56
57 void WebContentsViewAndroid::RequestExternalVideoSurface(int player_id) { 57 void WebContentsViewAndroid::RequestExternalVideoSurface(int player_id) {
58 if (content_view_core_) 58 if (content_view_core_)
59 content_view_core_->RequestExternalVideoSurface(player_id); 59 content_view_core_->RequestExternalVideoSurface(player_id);
60 } 60 }
61 61
62 void WebContentsViewAndroid::NotifyGeometryChange(int player_id,
63 const gfx::RectF& rect) {
64 if (content_view_core_)
65 content_view_core_->NotifyGeometryChange(player_id, rect);
66 }
67
62 gfx::NativeView WebContentsViewAndroid::GetNativeView() const { 68 gfx::NativeView WebContentsViewAndroid::GetNativeView() const {
63 return content_view_core_; 69 return content_view_core_;
64 } 70 }
65 71
66 gfx::NativeView WebContentsViewAndroid::GetContentNativeView() const { 72 gfx::NativeView WebContentsViewAndroid::GetContentNativeView() const {
67 return content_view_core_; 73 return content_view_core_;
68 } 74 }
69 75
70 gfx::NativeWindow WebContentsViewAndroid::GetTopLevelNativeWindow() const { 76 gfx::NativeWindow WebContentsViewAndroid::GetTopLevelNativeWindow() const {
71 return content_view_core_->GetWindowAndroid(); 77 return content_view_core_->GetWindowAndroid();
(...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after
216 // This is called when we the renderer asks us to take focus back (i.e., it has 222 // This is called when we the renderer asks us to take focus back (i.e., it has
217 // iterated past the last focusable element on the page). 223 // iterated past the last focusable element on the page).
218 void WebContentsViewAndroid::TakeFocus(bool reverse) { 224 void WebContentsViewAndroid::TakeFocus(bool reverse) {
219 if (web_contents_->GetDelegate() && 225 if (web_contents_->GetDelegate() &&
220 web_contents_->GetDelegate()->TakeFocus(web_contents_, reverse)) 226 web_contents_->GetDelegate()->TakeFocus(web_contents_, reverse))
221 return; 227 return;
222 web_contents_->GetRenderWidgetHostView()->Focus(); 228 web_contents_->GetRenderWidgetHostView()->Focus();
223 } 229 }
224 230
225 } // namespace content 231 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698