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_BLINK_CDM_RESULT_PROMISE_H_ | 5 #ifndef MEDIA_BLINK_CDM_RESULT_PROMISE_H_ |
6 #define MEDIA_BLINK_CDM_RESULT_PROMISE_H_ | 6 #define MEDIA_BLINK_CDM_RESULT_PROMISE_H_ |
7 | 7 |
| 8 #include <stdint.h> |
| 9 |
8 #include "base/macros.h" | 10 #include "base/macros.h" |
9 #include "media/base/cdm_promise.h" | 11 #include "media/base/cdm_promise.h" |
10 #include "media/base/media_keys.h" | 12 #include "media/base/media_keys.h" |
11 #include "media/blink/cdm_result_promise_helper.h" | 13 #include "media/blink/cdm_result_promise_helper.h" |
12 #include "third_party/WebKit/public/platform/WebContentDecryptionModuleResult.h" | 14 #include "third_party/WebKit/public/platform/WebContentDecryptionModuleResult.h" |
13 #include "third_party/WebKit/public/platform/WebString.h" | 15 #include "third_party/WebKit/public/platform/WebString.h" |
14 | 16 |
15 namespace media { | 17 namespace media { |
16 | 18 |
17 // Used to convert a WebContentDecryptionModuleResult into a CdmPromiseTemplate | 19 // Used to convert a WebContentDecryptionModuleResult into a CdmPromiseTemplate |
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
73 ReportCdmResultUMA(uma_name_, | 75 ReportCdmResultUMA(uma_name_, |
74 ConvertCdmExceptionToResultForUMA(exception_code)); | 76 ConvertCdmExceptionToResultForUMA(exception_code)); |
75 web_cdm_result_.completeWithError(ConvertCdmException(exception_code), | 77 web_cdm_result_.completeWithError(ConvertCdmException(exception_code), |
76 system_code, | 78 system_code, |
77 blink::WebString::fromUTF8(error_message)); | 79 blink::WebString::fromUTF8(error_message)); |
78 } | 80 } |
79 | 81 |
80 } // namespace media | 82 } // namespace media |
81 | 83 |
82 #endif // MEDIA_BLINK_CDM_RESULT_PROMISE_H_ | 84 #endif // MEDIA_BLINK_CDM_RESULT_PROMISE_H_ |
OLD | NEW |