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

Unified Diff: content/browser/android/media_player_manager_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: Put notification hook under ifdef's to minimize performance implication on other platforms 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/android/media_player_manager_android.cc
diff --git a/content/browser/android/media_player_manager_android.cc b/content/browser/android/media_player_manager_android.cc
index 7375ff72e17aec22f719eb08a94e2ec102cd5f98..f35abe64d61bac60aa0697510d8149f711a52ce6 100644
--- a/content/browser/android/media_player_manager_android.cc
+++ b/content/browser/android/media_player_manager_android.cc
@@ -47,6 +47,8 @@ bool MediaPlayerManagerAndroid::OnMessageReceived(const IPC::Message& msg) {
DestroyAllMediaPlayers)
IPC_MESSAGE_HANDLER(MediaPlayerHostMsg_RequestExternalSurface,
OnRequestExternalSurface)
+ IPC_MESSAGE_HANDLER(MediaPlayerHostMsg_NotifyGeometryChange,
+ OnNotifyGeometryChange)
IPC_MESSAGE_UNHANDLED(handled = false)
IPC_END_MESSAGE_MAP()
return handled;
@@ -225,6 +227,16 @@ void MediaPlayerManagerAndroid::OnRequestExternalSurface(int player_id) {
}
}
+void MediaPlayerManagerAndroid::OnNotifyGeometryChange(int player_id,
+ gfx::RectF rect) {
+ if (web_contents_) {
+ WebContentsViewAndroid* view =
+ static_cast<WebContentsViewAndroid*>(web_contents_->GetView());
+ if (view)
+ view->NotifyGeometryChange(player_id, rect);
+ }
+}
+
MediaPlayerBridge* MediaPlayerManagerAndroid::GetPlayer(int player_id) {
for (ScopedVector<MediaPlayerBridge>::iterator it = players_.begin();
it != players_.end(); ++it) {

Powered by Google App Engine
This is Rietveld 408576698