OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 #include "webkit/renderer/media/android/proxy_media_keys.h" | 5 #include "content/renderer/media/android/proxy_media_keys.h" |
6 | 6 |
7 #include "base/logging.h" | 7 #include "base/logging.h" |
8 #include "webkit/renderer/media/android/webmediaplayer_proxy_android.h" | 8 #include "content/renderer/media/android/webmediaplayer_proxy_android.h" |
9 | 9 |
10 namespace webkit_media { | 10 namespace content { |
11 | 11 |
12 ProxyMediaKeys::ProxyMediaKeys(WebMediaPlayerProxyAndroid* proxy, | 12 ProxyMediaKeys::ProxyMediaKeys(WebMediaPlayerProxyAndroid* proxy, |
13 int media_keys_id) | 13 int media_keys_id) |
14 : proxy_(proxy), media_keys_id_(media_keys_id) { | 14 : proxy_(proxy), media_keys_id_(media_keys_id) { |
15 DCHECK(proxy_); | 15 DCHECK(proxy_); |
16 } | 16 } |
17 | 17 |
18 bool ProxyMediaKeys::GenerateKeyRequest(const std::string& type, | 18 bool ProxyMediaKeys::GenerateKeyRequest(const std::string& type, |
19 const uint8* init_data, | 19 const uint8* init_data, |
20 int init_data_length) { | 20 int init_data_length) { |
(...skipping 10 matching lines...) Expand all Loading... |
31 proxy_->AddKey(media_keys_id_, | 31 proxy_->AddKey(media_keys_id_, |
32 std::vector<uint8>(key, key + key_length), | 32 std::vector<uint8>(key, key + key_length), |
33 std::vector<uint8>(init_data, init_data + init_data_length), | 33 std::vector<uint8>(init_data, init_data + init_data_length), |
34 session_id); | 34 session_id); |
35 } | 35 } |
36 | 36 |
37 void ProxyMediaKeys::CancelKeyRequest(const std::string& session_id) { | 37 void ProxyMediaKeys::CancelKeyRequest(const std::string& session_id) { |
38 proxy_->CancelKeyRequest(media_keys_id_, session_id); | 38 proxy_->CancelKeyRequest(media_keys_id_, session_id); |
39 } | 39 } |
40 | 40 |
41 } // namespace webkit_media | 41 } // namespace content |
OLD | NEW |