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

Unified Diff: content/renderer/media/webcontentdecryptionmodulesession_impl.cc

Issue 138753003: Update WebContentDecryptionModuleSessionImpl to latest EME API (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/media/webcontentdecryptionmodulesession_impl.cc
diff --git a/content/renderer/media/webcontentdecryptionmodulesession_impl.cc b/content/renderer/media/webcontentdecryptionmodulesession_impl.cc
index 1015d0ed680c2523a0373179067d17d4bdc6cd88..f9f0b55eb812a992f87a8a14a077d19a3efba709 100644
--- a/content/renderer/media/webcontentdecryptionmodulesession_impl.cc
+++ b/content/renderer/media/webcontentdecryptionmodulesession_impl.cc
@@ -72,18 +72,17 @@ void WebContentDecryptionModuleSessionImpl::OnSessionCreated(
void WebContentDecryptionModuleSessionImpl::OnSessionMessage(
const std::vector<uint8>& message,
const std::string& destination_url) {
- client_->keyMessage(message.empty() ? NULL : &message[0],
- message.size(),
- GURL(destination_url));
+ client_->message(message.empty() ? NULL : &message[0],
+ message.size(),
+ GURL(destination_url));
}
void WebContentDecryptionModuleSessionImpl::OnSessionReady() {
- // TODO(jrummell): Blink APIs need to be updated to the new EME API. For now,
- // convert the response to the old v0.1b API.
- client_->keyAdded();
+ client_->ready();
}
void WebContentDecryptionModuleSessionImpl::OnSessionClosed() {
+ client_->close();
if (!session_closed_cb_.is_null())
base::ResetAndReturn(&session_closed_cb_).Run(session_id_);
}
@@ -91,8 +90,8 @@ void WebContentDecryptionModuleSessionImpl::OnSessionClosed() {
void WebContentDecryptionModuleSessionImpl::OnSessionError(
media::MediaKeys::KeyError error_code,
int system_code) {
- client_->keyError(static_cast<Client::MediaKeyErrorCode>(error_code),
- system_code);
+ client_->error(static_cast<Client::MediaKeyErrorCode>(error_code),
+ system_code);
}
} // namespace content
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698