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

Unified Diff: content/renderer/media/crypto/proxy_media_keys.cc

Issue 555223004: Update MediaKeys interface for EME (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: comments Created 6 years, 3 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/renderer/media/crypto/proxy_media_keys.cc
diff --git a/content/renderer/media/crypto/proxy_media_keys.cc b/content/renderer/media/crypto/proxy_media_keys.cc
index 17e918d80ec2338c847244448525903fa3d047a1..267a0d1fc2fcf8c5b30b720400e1a02299667b8a 100644
--- a/content/renderer/media/crypto/proxy_media_keys.cc
+++ b/content/renderer/media/crypto/proxy_media_keys.cc
@@ -22,8 +22,13 @@ scoped_ptr<ProxyMediaKeys> ProxyMediaKeys::Create(
const media::SessionMessageCB& session_message_cb,
const media::SessionReadyCB& session_ready_cb,
const media::SessionClosedCB& session_closed_cb,
- const media::SessionErrorCB& session_error_cb) {
+ const media::SessionErrorCB& session_error_cb,
+ const media::SessionKeysChangeCB& session_keys_change_cb,
+ const media::SessionExpirationUpdateCB& session_expiration_update_cb) {
DCHECK(manager);
+
+ // TODO(jrummell): Add support for SessionKeysChangeCB and
+ // SessionExpirationUpdateCB.
scoped_ptr<ProxyMediaKeys> proxy_media_keys(
new ProxyMediaKeys(manager,
session_message_cb,
@@ -48,6 +53,13 @@ ProxyMediaKeys::~ProxyMediaKeys() {
session_id_to_promise_map_.clear();
}
+void ProxyMediaKeys::SetServerCertificate(
+ const uint8* certificate_data,
+ int certificate_data_length,
+ scoped_ptr<media::SimpleCdmPromise> promise) {
+ promise->reject(NOT_SUPPORTED_ERROR, 0, "Not yet implemented.");
+}
+
void ProxyMediaKeys::CreateSession(
const std::string& init_data_type,
const uint8* init_data,
@@ -107,9 +119,8 @@ void ProxyMediaKeys::UpdateSession(
std::vector<uint8>(response, response + response_length));
}
-void ProxyMediaKeys::ReleaseSession(
- const std::string& web_session_id,
- scoped_ptr<media::SimpleCdmPromise> promise) {
+void ProxyMediaKeys::CloseSession(const std::string& web_session_id,
+ scoped_ptr<media::SimpleCdmPromise> promise) {
uint32 session_id = LookupSessionId(web_session_id);
if (!session_id) {
promise->reject(INVALID_ACCESS_ERROR, 0, "Session does not exist.");
@@ -120,6 +131,17 @@ void ProxyMediaKeys::ReleaseSession(
manager_->ReleaseSession(cdm_id_, session_id);
}
+void ProxyMediaKeys::RemoveSession(
+ const std::string& web_session_id,
+ scoped_ptr<media::SimpleCdmPromise> promise) {
+ promise->reject(NOT_SUPPORTED_ERROR, 0, "Not yet implemented.");
+}
+
+void ProxyMediaKeys::GetUsableKeyIds(const std::string& web_session_id,
+ scoped_ptr<media::KeyIdsPromise> promise) {
+ promise->reject(NOT_SUPPORTED_ERROR, 0, "Not yet implemented.");
+}
+
void ProxyMediaKeys::OnSessionCreated(uint32 session_id,
const std::string& web_session_id) {
AssignWebSessionId(session_id, web_session_id);
« no previous file with comments | « content/renderer/media/crypto/proxy_media_keys.h ('k') | content/renderer/media/webcontentdecryptionmodule_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698