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

Unified Diff: media/blink/null_encrypted_media_player_support.cc

Issue 567803002: Hook WebMediaPlayerImpl up to Mojo's HTMLDocumentView. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address CR comment 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
« no previous file with comments | « media/blink/null_encrypted_media_player_support.h ('k') | media/blink/webmediaplayer_params.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/blink/null_encrypted_media_player_support.cc
diff --git a/media/blink/null_encrypted_media_player_support.cc b/media/blink/null_encrypted_media_player_support.cc
new file mode 100644
index 0000000000000000000000000000000000000000..035785bc9054984db4aa4722b61fd060f1d0b01c
--- /dev/null
+++ b/media/blink/null_encrypted_media_player_support.cc
@@ -0,0 +1,80 @@
+// Copyright 2014 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "media/blink/null_encrypted_media_player_support.h"
+
+#include "third_party/WebKit/public/platform/WebContentDecryptionModule.h"
+#include "third_party/WebKit/public/platform/WebContentDecryptionModuleResult.h"
+
+namespace media {
+
+scoped_ptr<EncryptedMediaPlayerSupport>
+NullEncryptedMediaPlayerSupport::Create(blink::WebMediaPlayerClient* client) {
+ return scoped_ptr<EncryptedMediaPlayerSupport>(
+ new NullEncryptedMediaPlayerSupport());
+}
+
+NullEncryptedMediaPlayerSupport::NullEncryptedMediaPlayerSupport() {
+}
+
+NullEncryptedMediaPlayerSupport::~NullEncryptedMediaPlayerSupport() {
+}
+
+blink::WebMediaPlayer::MediaKeyException
+NullEncryptedMediaPlayerSupport::GenerateKeyRequest(
+ blink::WebLocalFrame* frame,
+ const blink::WebString& key_system,
+ const unsigned char* init_data,
+ unsigned init_data_length) {
+ return blink::WebMediaPlayer::MediaKeyExceptionKeySystemNotSupported;
+}
+
+blink::WebMediaPlayer::MediaKeyException
+NullEncryptedMediaPlayerSupport::AddKey(
+ const blink::WebString& key_system,
+ const unsigned char* key,
+ unsigned key_length,
+ const unsigned char* init_data,
+ unsigned init_data_length,
+ const blink::WebString& session_id) {
+ return blink::WebMediaPlayer::MediaKeyExceptionKeySystemNotSupported;
+}
+
+blink::WebMediaPlayer::MediaKeyException
+NullEncryptedMediaPlayerSupport::CancelKeyRequest(
+ const blink::WebString& key_system,
+ const blink::WebString& session_id) {
+ return blink::WebMediaPlayer::MediaKeyExceptionKeySystemNotSupported;
+}
+
+void NullEncryptedMediaPlayerSupport::SetContentDecryptionModule(
+ blink::WebContentDecryptionModule* cdm) {
+}
+
+void NullEncryptedMediaPlayerSupport::SetContentDecryptionModule(
+ blink::WebContentDecryptionModule* cdm,
+ blink::WebContentDecryptionModuleResult result) {
+ result.completeWithError(
+ blink::WebContentDecryptionModuleExceptionNotSupportedError,
+ 0,
+ "Null MediaKeys object is not supported.");
+}
+
+void NullEncryptedMediaPlayerSupport::SetContentDecryptionModuleSync(
+ blink::WebContentDecryptionModule* cdm) {
+}
+
+Demuxer::NeedKeyCB NullEncryptedMediaPlayerSupport::CreateNeedKeyCB() {
+ return Demuxer::NeedKeyCB();
+}
+
+SetDecryptorReadyCB
+NullEncryptedMediaPlayerSupport::CreateSetDecryptorReadyCB() {
+ return SetDecryptorReadyCB();
+}
+
+void NullEncryptedMediaPlayerSupport::OnPipelineDecryptError() {
+}
+
+} // namespace media
« no previous file with comments | « media/blink/null_encrypted_media_player_support.h ('k') | media/blink/webmediaplayer_params.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698