OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 #ifndef COMPONENTS_CONTENT_SETTINGS_CORE_COMMON_CONTENT_SETTINGS_H_ | 5 #ifndef COMPONENTS_CONTENT_SETTINGS_CORE_COMMON_CONTENT_SETTINGS_H_ |
6 #define COMPONENTS_CONTENT_SETTINGS_CORE_COMMON_CONTENT_SETTINGS_H_ | 6 #define COMPONENTS_CONTENT_SETTINGS_CORE_COMMON_CONTENT_SETTINGS_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
53 struct RendererContentSettingRules { | 53 struct RendererContentSettingRules { |
54 RendererContentSettingRules(); | 54 RendererContentSettingRules(); |
55 ~RendererContentSettingRules(); | 55 ~RendererContentSettingRules(); |
56 ContentSettingsForOneType image_rules; | 56 ContentSettingsForOneType image_rules; |
57 ContentSettingsForOneType script_rules; | 57 ContentSettingsForOneType script_rules; |
58 }; | 58 }; |
59 | 59 |
60 namespace content_settings { | 60 namespace content_settings { |
61 | 61 |
62 // Enum containing the various source for content settings. Settings can be | 62 // Enum containing the various source for content settings. Settings can be |
63 // set by policy, extension or the user. Certain (internal) schemes are | 63 // set by policy, extension, the user or by the custodian of a supervised user. |
64 // whilelisted. For whilelisted schemes the source is | 64 // Certain (internal) schemes are whilelisted. For whilelisted schemes the |
65 // |SETTING_SOURCE_WHITELIST|. | 65 // source is |SETTING_SOURCE_WHITELIST|. |
66 enum SettingSource { | 66 enum SettingSource { |
67 SETTING_SOURCE_NONE, | 67 SETTING_SOURCE_NONE, |
68 SETTING_SOURCE_POLICY, | 68 SETTING_SOURCE_POLICY, |
69 SETTING_SOURCE_EXTENSION, | 69 SETTING_SOURCE_EXTENSION, |
70 SETTING_SOURCE_USER, | 70 SETTING_SOURCE_USER, |
71 SETTING_SOURCE_WHITELIST, | 71 SETTING_SOURCE_WHITELIST, |
| 72 SETTING_SOURCE_SUPERVISED, |
72 }; | 73 }; |
73 | 74 |
74 // |SettingInfo| provides meta data for content setting values. |source| | 75 // |SettingInfo| provides meta data for content setting values. |source| |
75 // contains the source of a value. |primary_pattern| and |secondary_pattern| | 76 // contains the source of a value. |primary_pattern| and |secondary_pattern| |
76 // contains the patterns of the appling rule. | 77 // contains the patterns of the appling rule. |
77 struct SettingInfo { | 78 struct SettingInfo { |
78 SettingSource source; | 79 SettingSource source; |
79 ContentSettingsPattern primary_pattern; | 80 ContentSettingsPattern primary_pattern; |
80 ContentSettingsPattern secondary_pattern; | 81 ContentSettingsPattern secondary_pattern; |
81 }; | 82 }; |
82 | 83 |
83 } // namespace content_settings | 84 } // namespace content_settings |
84 | 85 |
85 #endif // COMPONENTS_CONTENT_SETTINGS_CORE_COMMON_CONTENT_SETTINGS_H_ | 86 #endif // COMPONENTS_CONTENT_SETTINGS_CORE_COMMON_CONTENT_SETTINGS_H_ |
OLD | NEW |