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 #include "mojo/services/html_viewer/web_mime_registry_impl.h" | 5 #include "components/html_viewer/web_mime_registry_impl.h" |
6 | 6 |
7 #include "base/files/file_path.h" | 7 #include "base/files/file_path.h" |
8 #include "base/strings/string_util.h" | 8 #include "base/strings/string_util.h" |
9 #include "base/strings/sys_string_conversions.h" | 9 #include "base/strings/sys_string_conversions.h" |
10 #include "base/strings/utf_string_conversions.h" | 10 #include "base/strings/utf_string_conversions.h" |
11 #include "media/base/key_systems.h" | 11 #include "media/base/key_systems.h" |
12 #include "media/filters/stream_parser_factory.h" | 12 #include "media/filters/stream_parser_factory.h" |
13 #include "net/base/mime_util.h" | 13 #include "net/base/mime_util.h" |
14 #include "third_party/WebKit/public/platform/WebString.h" | 14 #include "third_party/WebKit/public/platform/WebString.h" |
15 | 15 |
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
127 | 127 |
128 blink::WebString WebMimeRegistryImpl::mimeTypeFromFile( | 128 blink::WebString WebMimeRegistryImpl::mimeTypeFromFile( |
129 const blink::WebString& file_path) { | 129 const blink::WebString& file_path) { |
130 std::string mime_type; | 130 std::string mime_type; |
131 net::GetMimeTypeFromFile(base::FilePath::FromUTF16Unsafe(file_path), | 131 net::GetMimeTypeFromFile(base::FilePath::FromUTF16Unsafe(file_path), |
132 &mime_type); | 132 &mime_type); |
133 return blink::WebString::fromUTF8(mime_type); | 133 return blink::WebString::fromUTF8(mime_type); |
134 } | 134 } |
135 | 135 |
136 } // namespace html_viewer | 136 } // namespace html_viewer |
OLD | NEW |