OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 <algorithm> | 5 #include <algorithm> |
6 #include <iterator> | 6 #include <iterator> |
7 #include <map> | 7 #include <map> |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "net/base/mime_util.h" | 10 #include "net/base/mime_util.h" |
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
122 { "text/css", "css" }, | 122 { "text/css", "css" }, |
123 { "text/xml", "xml" }, | 123 { "text/xml", "xml" }, |
124 { "image/gif", "gif" }, | 124 { "image/gif", "gif" }, |
125 { "image/jpeg", "jpeg,jpg" }, | 125 { "image/jpeg", "jpeg,jpg" }, |
126 { "image/webp", "webp" }, | 126 { "image/webp", "webp" }, |
127 { "image/png", "png" }, | 127 { "image/png", "png" }, |
128 { "video/mp4", "mp4,m4v" }, | 128 { "video/mp4", "mp4,m4v" }, |
129 { "audio/x-m4a", "m4a" }, | 129 { "audio/x-m4a", "m4a" }, |
130 { "audio/mp3", "mp3" }, | 130 { "audio/mp3", "mp3" }, |
131 { "video/ogg", "ogv,ogm" }, | 131 { "video/ogg", "ogv,ogm" }, |
132 { "audio/ogg", "ogg,oga" }, | 132 { "audio/ogg", "ogg,oga,opus" }, |
133 { "video/webm", "webm" }, | 133 { "video/webm", "webm" }, |
134 { "audio/webm", "webm" }, | 134 { "audio/webm", "webm" }, |
135 { "audio/wav", "wav" }, | 135 { "audio/wav", "wav" }, |
136 { "application/xhtml+xml", "xhtml,xht" }, | 136 { "application/xhtml+xml", "xhtml,xht" }, |
137 { "application/x-chrome-extension", "crx" }, | 137 { "application/x-chrome-extension", "crx" }, |
138 { "multipart/related", "mhtml,mht" } | 138 { "multipart/related", "mhtml,mht" } |
139 }; | 139 }; |
140 | 140 |
141 static const MimeInfo secondary_mappings[] = { | 141 static const MimeInfo secondary_mappings[] = { |
142 { "application/octet-stream", "exe,com,bin" }, | 142 { "application/octet-stream", "exe,com,bin" }, |
(...skipping 833 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
976 return CERTIFICATE_MIME_TYPE_UNKNOWN; | 976 return CERTIFICATE_MIME_TYPE_UNKNOWN; |
977 } | 977 } |
978 | 978 |
979 bool IsSupportedCertificateMimeType(const std::string& mime_type) { | 979 bool IsSupportedCertificateMimeType(const std::string& mime_type) { |
980 CertificateMimeType file_type = | 980 CertificateMimeType file_type = |
981 GetCertificateMimeTypeForMimeType(mime_type); | 981 GetCertificateMimeTypeForMimeType(mime_type); |
982 return file_type != CERTIFICATE_MIME_TYPE_UNKNOWN; | 982 return file_type != CERTIFICATE_MIME_TYPE_UNKNOWN; |
983 } | 983 } |
984 | 984 |
985 } // namespace net | 985 } // namespace net |
OLD | NEW |