| 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 CONTENT_RENDERER_MEDIA_CRYPTO_RENDERER_CDM_MANAGER_H_ | 5 #ifndef CONTENT_RENDERER_MEDIA_CRYPTO_RENDERER_CDM_MANAGER_H_ |
| 6 #define CONTENT_RENDERER_MEDIA_CRYPTO_RENDERER_CDM_MANAGER_H_ | 6 #define CONTENT_RENDERER_MEDIA_CRYPTO_RENDERER_CDM_MANAGER_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 15 matching lines...) Expand all Loading... |
| 26 // Class for managing all the CDM objects in the same RenderFrame. | 26 // Class for managing all the CDM objects in the same RenderFrame. |
| 27 class RendererCdmManager : public RenderFrameObserver { | 27 class RendererCdmManager : public RenderFrameObserver { |
| 28 public: | 28 public: |
| 29 static const int kInvalidCdmId = 0; | 29 static const int kInvalidCdmId = 0; |
| 30 | 30 |
| 31 // Constructs a RendererCdmManager object for the |render_frame|. | 31 // Constructs a RendererCdmManager object for the |render_frame|. |
| 32 explicit RendererCdmManager(RenderFrame* render_frame); | 32 explicit RendererCdmManager(RenderFrame* render_frame); |
| 33 virtual ~RendererCdmManager(); | 33 virtual ~RendererCdmManager(); |
| 34 | 34 |
| 35 // RenderFrameObserver overrides. | 35 // RenderFrameObserver overrides. |
| 36 virtual bool OnMessageReceived(const IPC::Message& msg) OVERRIDE; | 36 virtual bool OnMessageReceived(const IPC::Message& msg) override; |
| 37 | 37 |
| 38 // Encrypted media related methods. | 38 // Encrypted media related methods. |
| 39 void InitializeCdm(int cdm_id, | 39 void InitializeCdm(int cdm_id, |
| 40 ProxyMediaKeys* media_keys, | 40 ProxyMediaKeys* media_keys, |
| 41 const std::string& key_system, | 41 const std::string& key_system, |
| 42 const GURL& security_origin); | 42 const GURL& security_origin); |
| 43 void CreateSession(int cdm_id, | 43 void CreateSession(int cdm_id, |
| 44 uint32 session_id, | 44 uint32 session_id, |
| 45 CdmHostMsg_CreateSession_ContentType conent_type, | 45 CdmHostMsg_CreateSession_ContentType conent_type, |
| 46 const std::vector<uint8>& init_data); | 46 const std::vector<uint8>& init_data); |
| (...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 81 | 81 |
| 82 // CDM ID to ProxyMediaKeys mapping. | 82 // CDM ID to ProxyMediaKeys mapping. |
| 83 std::map<int, ProxyMediaKeys*> proxy_media_keys_map_; | 83 std::map<int, ProxyMediaKeys*> proxy_media_keys_map_; |
| 84 | 84 |
| 85 DISALLOW_COPY_AND_ASSIGN(RendererCdmManager); | 85 DISALLOW_COPY_AND_ASSIGN(RendererCdmManager); |
| 86 }; | 86 }; |
| 87 | 87 |
| 88 } // namespace content | 88 } // namespace content |
| 89 | 89 |
| 90 #endif // CONTENT_RENDERER_MEDIA_CRYPTO_RENDERER_CDM_MANAGER_H_ | 90 #endif // CONTENT_RENDERER_MEDIA_CRYPTO_RENDERER_CDM_MANAGER_H_ |
| OLD | NEW |