Chromium Code Reviews| Index: content/browser/web_contents/web_contents_android.cc |
| diff --git a/content/browser/web_contents/web_contents_android.cc b/content/browser/web_contents/web_contents_android.cc |
| index 26a70110b57363a81c24b59c6d95af7eda5d66f5..5dd421311e453eae0a8262bdf509b369f083c631 100644 |
| --- a/content/browser/web_contents/web_contents_android.cc |
| +++ b/content/browser/web_contents/web_contents_android.cc |
| @@ -184,6 +184,15 @@ void WebContentsAndroid::OnShow(JNIEnv* env, jobject obj) { |
| web_contents_->WasShown(); |
| } |
| +void WebContentsAndroid::ReleaseMediaPlayers(JNIEnv* env, jobject jobj) { |
| + RenderViewHostImpl* rvhi = static_cast<RenderViewHostImpl*>( |
| + web_contents_->GetRenderViewHost()); |
|
qinmin
2014/08/22 21:49:32
nit: indent -2
David Trainor- moved to gerrit
2014/08/25 18:11:43
Done.
|
| + if (rvhi && rvhi->GetMainFrame()) { |
|
qinmin
2014/08/22 21:49:32
indent -2 and below
David Trainor- moved to gerrit
2014/08/25 18:11:43
Done.
|
| + rvhi->media_web_contents_observer()->ReleaseAllMediaPlayers( |
| + rvhi->GetMainFrame()); |
| + } |
| +} |
| + |
| void WebContentsAndroid::PauseVideo() { |
| RenderViewHostImpl* rvhi = static_cast<RenderViewHostImpl*>( |
| web_contents_->GetRenderViewHost()); |