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 <map> | 5 #include <map> |
6 #include <string> | 6 #include <string> |
7 | 7 |
8 #include "net/base/mime_util.h" | 8 #include "net/base/mime_util.h" |
9 #include "net/base/platform_mime_util.h" | 9 #include "net/base/platform_mime_util.h" |
10 | 10 |
(...skipping 287 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
298 "text/vnd.chromium.ftp-dir", | 298 "text/vnd.chromium.ftp-dir", |
299 "text/", | 299 "text/", |
300 "image/svg+xml", // SVG is text-based XML, even though it has an image/ type | 300 "image/svg+xml", // SVG is text-based XML, even though it has an image/ type |
301 "application/xml", | 301 "application/xml", |
302 "application/xhtml+xml", | 302 "application/xhtml+xml", |
303 "application/rss+xml", | 303 "application/rss+xml", |
304 "application/atom+xml", | 304 "application/atom+xml", |
305 "application/json", | 305 "application/json", |
306 "application/x-x509-user-cert", | 306 "application/x-x509-user-cert", |
307 "multipart/related", // For MHTML support. | 307 "multipart/related", // For MHTML support. |
308 "multipart/x-mixed-replace" | 308 "multipart/x-mixed-replace", |
309 // Note: ADDING a new type here will probably render it AS HTML. This can | 309 // Note: ADDING a new type here will probably render it AS HTML. This can |
310 // result in cross site scripting. | 310 // result in cross site scripting. |
311 }; | 311 }; |
312 | 312 |
313 // Mozilla 1.8 and WinIE 7 both accept text/javascript and text/ecmascript. | 313 // Mozilla 1.8 and WinIE 7 both accept text/javascript and text/ecmascript. |
314 // Mozilla 1.8 accepts application/javascript, application/ecmascript, and | 314 // Mozilla 1.8 accepts application/javascript, application/ecmascript, and |
315 // application/x-javascript, but WinIE 7 doesn't. | 315 // application/x-javascript, but WinIE 7 doesn't. |
316 // WinIE 7 accepts text/javascript1.1 - text/javascript1.3, text/jscript, and | 316 // WinIE 7 accepts text/javascript1.1 - text/javascript1.3, text/jscript, and |
317 // text/livescript, but Mozilla 1.8 doesn't. | 317 // text/livescript, but Mozilla 1.8 doesn't. |
318 // Mozilla 1.8 allows leading and trailing whitespace, but WinIE 7 doesn't. | 318 // Mozilla 1.8 allows leading and trailing whitespace, but WinIE 7 doesn't. |
(...skipping 423 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
742 | 742 |
743 GetExtensionsFromHardCodedMappings(secondary_mappings, | 743 GetExtensionsFromHardCodedMappings(secondary_mappings, |
744 arraysize(secondary_mappings), | 744 arraysize(secondary_mappings), |
745 mime_type, | 745 mime_type, |
746 &unique_extensions); | 746 &unique_extensions); |
747 | 747 |
748 HashSetToVector(&unique_extensions, extensions); | 748 HashSetToVector(&unique_extensions, extensions); |
749 } | 749 } |
750 | 750 |
751 } // namespace net | 751 } // namespace net |
OLD | NEW |