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

Unified Diff: media/blink/encrypted_media_player_support.h

Issue 759933003: Move OnNeedKey() to WebMediaPlayerImpl. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years 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 | « no previous file | media/blink/encrypted_media_player_support.cc » ('j') | media/blink/webmediaplayer_impl.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/blink/encrypted_media_player_support.h
diff --git a/media/blink/encrypted_media_player_support.h b/media/blink/encrypted_media_player_support.h
index a80ff58f95ae30f8738eb7f4b4f17d788506d05b..fbee28689a4542e6766c33a93ecd9eb048f6292e 100644
--- a/media/blink/encrypted_media_player_support.h
+++ b/media/blink/encrypted_media_player_support.h
@@ -31,9 +31,7 @@ class WebContentDecryptionModuleImpl;
// Provides support to prefixed EME implementation.
// Do NOT add unprefixed EME functionality to this class!
-// TODO(xhwang): Move CreateNeedKeyCB() outside this class. Then when we
-// deprecate prefixed EME support, drop this whole file.
-
+// TODO(xhwang): When deprecating prefixed EME support, drop this whole file.
class EncryptedMediaPlayerSupport
: public base::SupportsWeakPtr<EncryptedMediaPlayerSupport> {
public:
@@ -48,6 +46,7 @@ class EncryptedMediaPlayerSupport
blink::WebMediaPlayer::MediaKeyException GenerateKeyRequest(
blink::WebLocalFrame* frame,
const blink::WebString& key_system,
+ const std::string& init_data_type,
const unsigned char* init_data,
unsigned init_data_length);
@@ -63,14 +62,13 @@ class EncryptedMediaPlayerSupport
const blink::WebString& key_system,
const blink::WebString& session_id);
- Demuxer::NeedKeyCB CreateNeedKeyCB();
-
void OnPipelineDecryptError();
private:
blink::WebMediaPlayer::MediaKeyException GenerateKeyRequestInternal(
blink::WebLocalFrame* frame,
const std::string& key_system,
+ const std::string& init_data_type,
const unsigned char* init_data,
unsigned init_data_length);
@@ -86,9 +84,6 @@ class EncryptedMediaPlayerSupport
const std::string& key_system,
const std::string& session_id);
- void OnNeedKey(const std::string& type,
- const std::vector<uint8>& init_data);
-
void OnKeyAdded(const std::string& session_id);
void OnKeyError(const std::string& session_id,
MediaKeys::KeyError error_code,
@@ -105,10 +100,6 @@ class EncryptedMediaPlayerSupport
// has been selected.
std::string current_key_system_;
- // Temporary for EME v0.1. In the future the init data type should be passed
- // through GenerateKeyRequest() directly from WebKit.
- std::string init_data_type_;
-
SetCdmContextCB set_cdm_context_cb_;
// Manages decryption keys and decrypts encrypted frames.
« no previous file with comments | « no previous file | media/blink/encrypted_media_player_support.cc » ('j') | media/blink/webmediaplayer_impl.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698