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

Unified Diff: media/blink/key_system_config_selector.cc

Issue 1129643002: Moved media mime type and codec checks to media/base/mime_util.* (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Use media/base/mime_util.h in //components/mime_util/DEPS Created 5 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « media/base/mime_util_unittest.cc ('k') | media/media.gyp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/blink/key_system_config_selector.cc
diff --git a/media/blink/key_system_config_selector.cc b/media/blink/key_system_config_selector.cc
index f34bd8fc463cfb00ea9d5b3a1029653ae34805af..65db263c19e487e0b680896959ad31947a612d3b 100644
--- a/media/blink/key_system_config_selector.cc
+++ b/media/blink/key_system_config_selector.cc
@@ -10,8 +10,8 @@
#include "base/strings/utf_string_conversions.h"
#include "media/base/key_systems.h"
#include "media/base/media_permission.h"
+#include "media/base/mime_util.h"
#include "media/blink/webmediaplayer_util.h"
-#include "net/base/mime_util.h"
#include "third_party/WebKit/public/platform/WebMediaKeySystemConfiguration.h"
#include "third_party/WebKit/public/platform/WebSecurityOrigin.h"
#include "third_party/WebKit/public/platform/WebString.h"
@@ -283,7 +283,7 @@ bool KeySystemConfigSelector::IsSupportedContentType(
std::string container_lower = base::StringToLowerASCII(container_mime_type);
// Check that |container_mime_type| is supported by Chrome.
- if (!net::IsSupportedMediaMimeType(container_lower))
+ if (!media::IsSupportedMediaMimeType(container_lower))
return false;
// Check that |codecs| are supported by Chrome. This is done primarily to
@@ -291,10 +291,10 @@ bool KeySystemConfigSelector::IsSupportedContentType(
// codecs that Chrome does not (which could complicate the robustness
// algorithm).
std::vector<std::string> codec_vector;
- net::ParseCodecString(codecs, &codec_vector, false);
+ media::ParseCodecString(codecs, &codec_vector, false);
if (!codec_vector.empty() &&
- (net::IsSupportedStrictMediaMimeType(container_lower, codec_vector) !=
- net::IsSupported)) {
+ (media::IsSupportedStrictMediaMimeType(container_lower, codec_vector) !=
+ media::IsSupported)) {
return false;
}
@@ -302,7 +302,7 @@ bool KeySystemConfigSelector::IsSupportedContentType(
// This check does not handle extended codecs, so extended codec information
// is stripped (extended codec information was checked above).
std::vector<std::string> stripped_codec_vector;
- net::ParseCodecString(codecs, &stripped_codec_vector, true);
+ media::ParseCodecString(codecs, &stripped_codec_vector, true);
EmeConfigRule codecs_rule = key_systems_->GetContentTypeConfigRule(
key_system, media_type, container_lower, stripped_codec_vector);
if (!config_state->IsRuleSupported(codecs_rule))
« no previous file with comments | « media/base/mime_util_unittest.cc ('k') | media/media.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698