OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 #ifndef MEDIA_CDM_PPAPI_CDM_WRAPPER_H_ | 5 #ifndef MEDIA_CDM_PPAPI_CDM_WRAPPER_H_ |
6 #define MEDIA_CDM_PPAPI_CDM_WRAPPER_H_ | 6 #define MEDIA_CDM_PPAPI_CDM_WRAPPER_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "media/cdm/ppapi/api/content_decryption_module.h" | 9 #include "media/cdm/ppapi/api/content_decryption_module.h" |
10 #include "media/cdm/ppapi/cdm_helpers.h" | 10 #include "media/cdm/ppapi/cdm_helpers.h" |
(...skipping 211 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
222 if (cdm_adapter) | 222 if (cdm_adapter) |
223 return cdm_adapter; | 223 return cdm_adapter; |
224 | 224 |
225 // Try to see if the CDM supports older version(s) of CDM interface(s). | 225 // Try to see if the CDM supports older version(s) of CDM interface(s). |
226 cdm_adapter = CdmWrapperImpl<cdm::ContentDecryptionModule_1>::Create( | 226 cdm_adapter = CdmWrapperImpl<cdm::ContentDecryptionModule_1>::Create( |
227 key_system, key_system_size, get_cdm_host_func, user_data); | 227 key_system, key_system_size, get_cdm_host_func, user_data); |
228 return cdm_adapter; | 228 return cdm_adapter; |
229 } | 229 } |
230 | 230 |
231 // When updating the CdmAdapter, ensure you've updated the CdmWrapper to contain | 231 // When updating the CdmAdapter, ensure you've updated the CdmWrapper to contain |
232 // stub implementations for new or modified methods which the older CDM | 232 // stub implementations for new or modified methods that the older CDM interface |
233 // interface does not have. | 233 // does not have. |
234 COMPILE_ASSERT(cdm::ContentDecryptionModule_2::kVersion == | 234 COMPILE_ASSERT(cdm::ContentDecryptionModule::kVersion == |
235 cdm::ContentDecryptionModule::kVersion, | 235 cdm::ContentDecryptionModule_2::kVersion, |
236 ensure_cdm_wrapper_templates_have_old_version_support); | 236 ensure_cdm_wrapper_templates_have_old_version_support); |
237 | 237 |
238 } // namespace media | 238 } // namespace media |
239 | 239 |
240 #endif // MEDIA_CDM_PPAPI_CDM_WRAPPER_H_ | 240 #endif // MEDIA_CDM_PPAPI_CDM_WRAPPER_H_ |
OLD | NEW |