Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(68)

Side by Side Diff: media/blink/webencryptedmediaclient_impl.cc

Issue 875073004: Don't update Media.EME.KeySystemSupport UMA for unprefixed EME (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 #include "webencryptedmediaclient_impl.h" 5 #include "webencryptedmediaclient_impl.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "base/strings/string_util.h" 8 #include "base/strings/string_util.h"
9 #include "base/strings/utf_string_conversions.h" 9 #include "base/strings/utf_string_conversions.h"
10 #include "media/base/key_systems.h" 10 #include "media/base/key_systems.h"
(...skipping 15 matching lines...) Expand all
26 // - audioCapabilitys: audio/mp4 or audio/webm. 26 // - audioCapabilitys: audio/mp4 or audio/webm.
27 // - videoCapabilitys: video/mp4 or video/webm. 27 // - videoCapabilitys: video/mp4 or video/webm.
28 // http://crbug.com/429781. 28 // http://crbug.com/429781.
29 std::string container = base::StringToLowerASCII(mime_type); 29 std::string container = base::StringToLowerASCII(mime_type);
30 30
31 // TODO(sandersd): Strict checking for codecs. http://crbug.com/374751. 31 // TODO(sandersd): Strict checking for codecs. http://crbug.com/374751.
32 bool strip_codec_suffixes = !net::IsStrictMediaMimeType(container); 32 bool strip_codec_suffixes = !net::IsStrictMediaMimeType(container);
33 std::vector<std::string> codec_vector; 33 std::vector<std::string> codec_vector;
34 net::ParseCodecString(codecs, &codec_vector, strip_codec_suffixes); 34 net::ParseCodecString(codecs, &codec_vector, strip_codec_suffixes);
35 return IsSupportedKeySystemWithMediaMimeType(container, codec_vector, 35 return IsSupportedKeySystemWithMediaMimeType(container, codec_vector,
36 key_system); 36 key_system, false);
37 } 37 }
38 38
39 static bool GetSupportedConfiguration( 39 static bool GetSupportedConfiguration(
40 const std::string& key_system, 40 const std::string& key_system,
41 const blink::WebMediaKeySystemConfiguration& candidate, 41 const blink::WebMediaKeySystemConfiguration& candidate,
42 const blink::WebSecurityOrigin& security_origin, 42 const blink::WebSecurityOrigin& security_origin,
43 blink::WebMediaKeySystemConfiguration* accumulated_configuration) { 43 blink::WebMediaKeySystemConfiguration* accumulated_configuration) {
44 if (!candidate.initDataTypes.isEmpty()) { 44 if (!candidate.initDataTypes.isEmpty()) {
45 std::vector<blink::WebString> init_data_types; 45 std::vector<blink::WebString> init_data_types;
46 46
(...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after
191 return; 191 return;
192 } 192 }
193 } 193 }
194 194
195 // 7.4 Reject promise with a new DOMException whose name is NotSupportedError. 195 // 7.4 Reject promise with a new DOMException whose name is NotSupportedError.
196 request.requestNotSupported( 196 request.requestNotSupported(
197 "None of the requested configurations were supported."); 197 "None of the requested configurations were supported.");
198 } 198 }
199 199
200 } // namespace media 200 } // namespace media
OLDNEW
« content/renderer/renderer_blink_platform_impl.cc ('K') | « media/base/key_systems_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698