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

Side by Side Diff: media/mojo/services/mojo_cdm_service.cc

Issue 813683005: Add |legacy_destination_url| back to SessionMessage for EME (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: changes Created 5 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 unified diff | Download patch
« no previous file with comments | « media/mojo/services/mojo_cdm_service.h ('k') | media/test/pipeline_integration_test.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "media/mojo/services/mojo_cdm_service.h" 5 #include "media/mojo/services/mojo_cdm_service.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "media/base/cdm_key_information.h" 8 #include "media/base/cdm_key_information.h"
9 #include "media/base/key_systems.h" 9 #include "media/base/key_systems.h"
10 #include "media/cdm/aes_decryptor.h" 10 #include "media/cdm/aes_decryptor.h"
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
101 } 101 }
102 102
103 void MojoCdmService::GetCdmContext( 103 void MojoCdmService::GetCdmContext(
104 int32_t cdm_id, 104 int32_t cdm_id,
105 mojo::InterfaceRequest<mojo::Decryptor> decryptor) { 105 mojo::InterfaceRequest<mojo::Decryptor> decryptor) {
106 NOTIMPLEMENTED(); 106 NOTIMPLEMENTED();
107 } 107 }
108 108
109 void MojoCdmService::OnSessionMessage(const std::string& session_id, 109 void MojoCdmService::OnSessionMessage(const std::string& session_id,
110 MediaKeys::MessageType message_type, 110 MediaKeys::MessageType message_type,
111 const std::vector<uint8_t>& message) { 111 const std::vector<uint8_t>& message,
112 const GURL& legacy_destination_url) {
112 client()->OnSessionMessage(session_id, 113 client()->OnSessionMessage(session_id,
113 static_cast<mojo::CdmMessageType>(message_type), 114 static_cast<mojo::CdmMessageType>(message_type),
114 mojo::Array<uint8_t>::From(message)); 115 mojo::Array<uint8_t>::From(message),
116 mojo::String::From(legacy_destination_url));
115 } 117 }
116 118
117 void MojoCdmService::OnSessionKeysChange(const std::string& session_id, 119 void MojoCdmService::OnSessionKeysChange(const std::string& session_id,
118 bool has_additional_usable_key, 120 bool has_additional_usable_key,
119 CdmKeysInfo keys_info) { 121 CdmKeysInfo keys_info) {
120 mojo::Array<mojo::CdmKeyInformationPtr> keys_data; 122 mojo::Array<mojo::CdmKeyInformationPtr> keys_data;
121 for (const auto& key : keys_info) 123 for (const auto& key : keys_info)
122 keys_data.push_back(mojo::CdmKeyInformation::From(*key)); 124 keys_data.push_back(mojo::CdmKeyInformation::From(*key));
123 client()->OnSessionKeysChange(session_id, has_additional_usable_key, 125 client()->OnSessionKeysChange(session_id, has_additional_usable_key,
124 keys_data.Pass()); 126 keys_data.Pass());
(...skipping 13 matching lines...) Expand all
138 void MojoCdmService::OnSessionError(const std::string& session_id, 140 void MojoCdmService::OnSessionError(const std::string& session_id,
139 MediaKeys::Exception exception, 141 MediaKeys::Exception exception,
140 uint32_t system_code, 142 uint32_t system_code,
141 const std::string& error_message) { 143 const std::string& error_message) {
142 client()->OnSessionError(session_id, 144 client()->OnSessionError(session_id,
143 static_cast<mojo::CdmException>(exception), 145 static_cast<mojo::CdmException>(exception),
144 system_code, error_message); 146 system_code, error_message);
145 } 147 }
146 148
147 } // namespace media 149 } // namespace media
OLDNEW
« no previous file with comments | « media/mojo/services/mojo_cdm_service.h ('k') | media/test/pipeline_integration_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698