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

Unified Diff: webkit/media/webmediaplayer_proxy.cc

Issue 11226019: Encrypted Media: Replace DecryptorClient with key event callbacks. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: rebase again Created 8 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
Index: webkit/media/webmediaplayer_proxy.cc
diff --git a/webkit/media/webmediaplayer_proxy.cc b/webkit/media/webmediaplayer_proxy.cc
index 8815f78efad4a82297b3a5e78bfac8e6bb0f06c4..3f604b3bd7f9831b28be318ad843edf470b24891 100644
--- a/webkit/media/webmediaplayer_proxy.cc
+++ b/webkit/media/webmediaplayer_proxy.cc
@@ -107,81 +107,4 @@ void WebMediaPlayerProxy::PutCurrentFrame(
frame_provider_->PutCurrentFrame(frame);
}
-
-void WebMediaPlayerProxy::KeyAdded(const std::string& key_system,
- const std::string& session_id) {
- render_loop_->PostTask(FROM_HERE, base::Bind(
- &WebMediaPlayerProxy::KeyAddedTask, this, key_system, session_id));
-}
-
-void WebMediaPlayerProxy::KeyError(const std::string& key_system,
- const std::string& session_id,
- media::Decryptor::KeyError error_code,
- int system_code) {
- render_loop_->PostTask(FROM_HERE, base::Bind(
- &WebMediaPlayerProxy::KeyErrorTask, this, key_system, session_id,
- error_code, system_code));
-}
-
-void WebMediaPlayerProxy::KeyMessage(const std::string& key_system,
- const std::string& session_id,
- const std::string& message,
- const std::string& default_url) {
- render_loop_->PostTask(FROM_HERE, base::Bind(
- &WebMediaPlayerProxy::KeyMessageTask, this, key_system, session_id,
- message, default_url));
-}
-
-void WebMediaPlayerProxy::NeedKey(const std::string& key_system,
- const std::string& session_id,
- const std::string& type,
- scoped_array<uint8> init_data,
- int init_data_size) {
- render_loop_->PostTask(FROM_HERE, base::Bind(
- &WebMediaPlayerProxy::NeedKeyTask, this, key_system, session_id, type,
- base::Passed(&init_data), init_data_size));
-}
-
-void WebMediaPlayerProxy::KeyAddedTask(const std::string& key_system,
- const std::string& session_id) {
- DCHECK(render_loop_->BelongsToCurrentThread());
- if (webmediaplayer_)
- webmediaplayer_->OnKeyAdded(key_system, session_id);
-}
-
-void WebMediaPlayerProxy::KeyErrorTask(const std::string& key_system,
- const std::string& session_id,
- media::Decryptor::KeyError error_code,
- int system_code) {
- DCHECK(render_loop_->BelongsToCurrentThread());
- if (webmediaplayer_)
- webmediaplayer_->OnKeyError(key_system, session_id,
- error_code, system_code);
-}
-
-void WebMediaPlayerProxy::KeyMessageTask(const std::string& key_system,
- const std::string& session_id,
- const std::string& message,
- const std::string& default_url) {
- DCHECK(render_loop_->BelongsToCurrentThread());
- if (webmediaplayer_) {
- const GURL default_url_gurl(default_url);
- DLOG_IF(WARNING, !default_url.empty() && !default_url_gurl.is_valid())
- << "Invalid URL in default_url: " << default_url;
- webmediaplayer_->OnKeyMessage(key_system, session_id, message,
- default_url_gurl);
- }
-}
-
-void WebMediaPlayerProxy::NeedKeyTask(const std::string& key_system,
- const std::string& session_id,
- const std::string& type,
- scoped_array<uint8> init_data,
- int init_data_size) {
- DCHECK(render_loop_->BelongsToCurrentThread());
- if (webmediaplayer_)
- webmediaplayer_->OnNeedKey(key_system, session_id, type,
- init_data.Pass(), init_data_size);
-}
-
} // namespace webkit_media

Powered by Google App Engine
This is Rietveld 408576698