Line data Source code
1 : /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 : /* vim: set ts=8 sts=2 et sw=2 tw=80: */
3 : /* This Source Code Form is subject to the terms of the Mozilla Public
4 : * License, v. 2.0. If a copy of the MPL was not distributed with this
5 : * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
6 :
7 : /*
8 : * enum for whether a CSS feature (property, pseudo-class, etc.) is
9 : * enabled in a specific context
10 : */
11 :
12 : #ifndef mozilla_CSSEnabledState_h
13 : #define mozilla_CSSEnabledState_h
14 :
15 : #include "mozilla/TypedEnumBits.h"
16 :
17 : namespace mozilla {
18 :
19 : enum class CSSEnabledState
20 : {
21 : // The default CSSEnabledState: only enable what's enabled for all
22 : // content, given the current values of preferences.
23 : eForAllContent = 0,
24 : // Enable features available in UA sheets.
25 : eInUASheets = 0x01,
26 : // Enable features available in chrome code.
27 : eInChrome = 0x02,
28 : // Special value to unconditionally enable everything. This implies
29 : // all the bits above, but is strictly more than just their OR-ed
30 : // union. This just skips any test so a feature will be enabled even
31 : // if it would have been disabled with all the bits above set.
32 : eIgnoreEnabledState = 0xff
33 : };
34 :
35 53327 : MOZ_MAKE_ENUM_CLASS_BITWISE_OPERATORS(CSSEnabledState)
36 :
37 : } // namespace mozilla
38 :
39 : #endif // mozilla_CSSEnabledState_h
|