OLD | NEW |
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 #ifndef MEDIA_MOJO_SERVICES_MOJO_CDM_SERVICE_H_ | 5 #ifndef MEDIA_MOJO_SERVICES_MOJO_CDM_SERVICE_H_ |
6 #define MEDIA_MOJO_SERVICES_MOJO_CDM_SERVICE_H_ | 6 #define MEDIA_MOJO_SERVICES_MOJO_CDM_SERVICE_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include "base/callback.h" | 10 #include "base/callback.h" |
11 #include "base/macros.h" | 11 #include "base/macros.h" |
12 #include "base/memory/ref_counted.h" | 12 #include "base/memory/ref_counted.h" |
13 #include "base/memory/scoped_ptr.h" | 13 #include "base/memory/scoped_ptr.h" |
14 #include "base/memory/weak_ptr.h" | 14 #include "base/memory/weak_ptr.h" |
15 #include "media/base/media_keys.h" | 15 #include "media/base/media_keys.h" |
16 #include "media/mojo/interfaces/content_decryption_module.mojom.h" | 16 #include "media/mojo/interfaces/content_decryption_module.mojom.h" |
17 #include "media/mojo/services/mojo_cdm_promise.h" | 17 #include "media/mojo/services/mojo_cdm_promise.h" |
18 #include "media/mojo/services/mojo_cdm_service_context.h" | 18 #include "media/mojo/services/mojo_cdm_service_context.h" |
19 #include "media/mojo/services/mojo_decryptor_service.h" | 19 #include "media/mojo/services/mojo_decryptor_service.h" |
20 #include "mojo/application/public/interfaces/service_provider.mojom.h" | |
21 #include "mojo/public/cpp/bindings/strong_binding.h" | 20 #include "mojo/public/cpp/bindings/strong_binding.h" |
| 21 #include "mojo/shell/public/interfaces/service_provider.mojom.h" |
22 | 22 |
23 namespace media { | 23 namespace media { |
24 | 24 |
25 class CdmFactory; | 25 class CdmFactory; |
26 | 26 |
27 // A interfaces::ContentDecryptionModule implementation backed by a | 27 // A interfaces::ContentDecryptionModule implementation backed by a |
28 // media::MediaKeys. | 28 // media::MediaKeys. |
29 class MojoCdmService : public interfaces::ContentDecryptionModule { | 29 class MojoCdmService : public interfaces::ContentDecryptionModule { |
30 public: | 30 public: |
31 // Get the CDM associated with |cdm_id|, which is unique per process. | 31 // Get the CDM associated with |cdm_id|, which is unique per process. |
(...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
130 | 130 |
131 base::WeakPtr<MojoCdmService> weak_this_; | 131 base::WeakPtr<MojoCdmService> weak_this_; |
132 base::WeakPtrFactory<MojoCdmService> weak_factory_; | 132 base::WeakPtrFactory<MojoCdmService> weak_factory_; |
133 | 133 |
134 DISALLOW_COPY_AND_ASSIGN(MojoCdmService); | 134 DISALLOW_COPY_AND_ASSIGN(MojoCdmService); |
135 }; | 135 }; |
136 | 136 |
137 } // namespace media | 137 } // namespace media |
138 | 138 |
139 #endif // MEDIA_MOJO_SERVICES_MOJO_CDM_SERVICE_H_ | 139 #endif // MEDIA_MOJO_SERVICES_MOJO_CDM_SERVICE_H_ |
OLD | NEW |