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

Unified Diff: content/renderer/media/android/webmediaplayer_android.cc

Issue 887873003: media: Add DefaultMediaPermission. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase only Created 5 years, 11 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
« no previous file with comments | « content/renderer/media/android/webmediaplayer_android.h ('k') | content/renderer/render_frame_impl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/media/android/webmediaplayer_android.cc
diff --git a/content/renderer/media/android/webmediaplayer_android.cc b/content/renderer/media/android/webmediaplayer_android.cc
index c35007d1e672f74ecfdbcfa7bb6301d4b6c4f4d2..f685b225db85b78db0d1789cf9efc26f18daa7fa 100644
--- a/content/renderer/media/android/webmediaplayer_android.cc
+++ b/content/renderer/media/android/webmediaplayer_android.cc
@@ -147,6 +147,7 @@ WebMediaPlayerAndroid::WebMediaPlayerAndroid(
base::WeakPtr<media::WebMediaPlayerDelegate> delegate,
RendererMediaPlayerManager* player_manager,
RendererCdmManager* cdm_manager,
+ media::MediaPermission* media_permission,
blink::WebContentDecryptionModule* initial_cdm,
scoped_refptr<StreamTextureFactory> factory,
const scoped_refptr<base::SingleThreadTaskRunner>& task_runner,
@@ -163,6 +164,7 @@ WebMediaPlayerAndroid::WebMediaPlayerAndroid(
did_loading_progress_(false),
player_manager_(player_manager),
cdm_manager_(cdm_manager),
+ media_permission_(media_permission),
network_state_(WebMediaPlayer::NetworkStateEmpty),
ready_state_(WebMediaPlayer::ReadyStateHaveNothing),
texture_id_(0),
@@ -1510,6 +1512,7 @@ WebMediaPlayerAndroid::GenerateKeyRequestInternal(
if (current_key_system_.empty()) {
if (!proxy_decryptor_) {
proxy_decryptor_.reset(new media::ProxyDecryptor(
+ media_permission_,
base::Bind(&WebMediaPlayerAndroid::OnKeyAdded,
weak_factory_.GetWeakPtr()),
base::Bind(&WebMediaPlayerAndroid::OnKeyError,
« no previous file with comments | « content/renderer/media/android/webmediaplayer_android.h ('k') | content/renderer/render_frame_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698