Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(324)

Side by Side Diff: components/content_settings/core/common/content_settings.h

Issue 1865803002: [Policy Experimental] Add policies to allow Cookies and Pop-ups exceptions. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Sync; compile fix in PolicyProvider::GetUserExceptionsUsageSettingForType(). Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 <stddef.h> 8 #include <stddef.h>
9 9
10 #include <string> 10 #include <string>
(...skipping 10 matching lines...) Expand all
21 enum ContentSetting { 21 enum ContentSetting {
22 CONTENT_SETTING_DEFAULT = 0, 22 CONTENT_SETTING_DEFAULT = 0,
23 CONTENT_SETTING_ALLOW, 23 CONTENT_SETTING_ALLOW,
24 CONTENT_SETTING_BLOCK, 24 CONTENT_SETTING_BLOCK,
25 CONTENT_SETTING_ASK, 25 CONTENT_SETTING_ASK,
26 CONTENT_SETTING_SESSION_ONLY, 26 CONTENT_SETTING_SESSION_ONLY,
27 CONTENT_SETTING_DETECT_IMPORTANT_CONTENT, 27 CONTENT_SETTING_DETECT_IMPORTANT_CONTENT,
28 CONTENT_SETTING_NUM_SETTINGS 28 CONTENT_SETTING_NUM_SETTINGS
29 }; 29 };
30 30
31 enum ContentSettingsUserExceptionsUsage {
32 USER_EXCEPTIONS_DEFAULT = 137, // DO NOT SUBMIT(huangs): Make this 0.
33 USER_EXCEPTIONS_ALLOW,
34 };
35
31 // Range-checked conversion of an int to a ContentSetting, for use when reading 36 // Range-checked conversion of an int to a ContentSetting, for use when reading
32 // prefs off disk. 37 // prefs off disk.
33 ContentSetting IntToContentSetting(int content_setting); 38 ContentSetting IntToContentSetting(int content_setting);
34 39
35 // Converts a given content setting to its histogram value, for use when saving 40 // Converts a given content setting to its histogram value, for use when saving
36 // content settings types to a histogram. 41 // content settings types to a histogram.
37 int ContentSettingTypeToHistogramValue(ContentSettingsType content_setting, 42 int ContentSettingTypeToHistogramValue(ContentSettingsType content_setting,
38 size_t* num_values); 43 size_t* num_values);
39 44
40 struct ContentSettingPatternSource { 45 struct ContentSettingPatternSource {
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 // contains the patterns of the appling rule. 88 // contains the patterns of the appling rule.
84 struct SettingInfo { 89 struct SettingInfo {
85 SettingSource source; 90 SettingSource source;
86 ContentSettingsPattern primary_pattern; 91 ContentSettingsPattern primary_pattern;
87 ContentSettingsPattern secondary_pattern; 92 ContentSettingsPattern secondary_pattern;
88 }; 93 };
89 94
90 } // namespace content_settings 95 } // namespace content_settings
91 96
92 #endif // COMPONENTS_CONTENT_SETTINGS_CORE_COMMON_CONTENT_SETTINGS_H_ 97 #endif // COMPONENTS_CONTENT_SETTINGS_CORE_COMMON_CONTENT_SETTINGS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698