1 /* This Source Code Form is subject to the terms of the Mozilla Public
2 * License, v. 2.0. If a copy of the MPL was not distributed with this file,
3 * You can obtain one at http://mozilla.org/MPL/2.0/. */
5 #ifndef nsCharsetSource_h_
6 #define nsCharsetSource_h_
8 // note: the value order defines the priority; higher numbers take priority
9 #define kCharsetUninitialized 0
10 #define kCharsetFromFallback 1
11 #define kCharsetFromTopLevelDomain 2
12 #define kCharsetFromDocTypeDefault 3 // This and up confident for XHR
13 #define kCharsetFromCache 4
14 #define kCharsetFromParentFrame 5
15 #define kCharsetFromAutoDetection 6
16 #define kCharsetFromHintPrevDoc 7
17 #define kCharsetFromMetaPrescan 8 // this one and smaller: HTML5 Tentative
18 #define kCharsetFromMetaTag 9 // this one and greater: HTML5 Confident
19 #define kCharsetFromIrreversibleAutoDetection 10
20 #define kCharsetFromChannel 11
21 #define kCharsetFromOtherComponent 12
22 #define kCharsetFromParentForced 13 // propagates to child frames
23 #define kCharsetFromUserForced 14 // propagates to child frames
24 #define kCharsetFromByteOrderMark 15
25 #define kCharsetFromUtf8OnlyMime 16 // For JSON, WebVTT and such
27 #endif /* nsCharsetSource_h_ */