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 #include "components/content_settings/core/common/content_settings.h" | 5 #include "components/content_settings/core/common/content_settings.h" |
6 | 6 |
7 #include "base/containers/hash_tables.h" | 7 #include "base/containers/hash_tables.h" |
8 #include "base/logging.h" | 8 #include "base/logging.h" |
9 #include "base/macros.h" | 9 #include "base/macros.h" |
10 #include "base/stl_util.h" | 10 #include "base/stl_util.h" |
| 11 #include "build/build_config.h" |
11 | 12 |
12 ContentSetting IntToContentSetting(int content_setting) { | 13 ContentSetting IntToContentSetting(int content_setting) { |
13 return ((content_setting < 0) || | 14 return ((content_setting < 0) || |
14 (content_setting >= CONTENT_SETTING_NUM_SETTINGS)) ? | 15 (content_setting >= CONTENT_SETTING_NUM_SETTINGS)) ? |
15 CONTENT_SETTING_DEFAULT : static_cast<ContentSetting>(content_setting); | 16 CONTENT_SETTING_DEFAULT : static_cast<ContentSetting>(content_setting); |
16 } | 17 } |
17 | 18 |
18 // WARNING: This array should not be reordered or removed as it is used for | 19 // WARNING: This array should not be reordered or removed as it is used for |
19 // histogram values. If a ContentSettingsType value has been removed, the entry | 20 // histogram values. If a ContentSettingsType value has been removed, the entry |
20 // must be replaced by a placeholder. It should correspond directly to the | 21 // must be replaced by a placeholder. It should correspond directly to the |
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
82 source(source), | 83 source(source), |
83 incognito(incognito) {} | 84 incognito(incognito) {} |
84 | 85 |
85 ContentSettingPatternSource::ContentSettingPatternSource() | 86 ContentSettingPatternSource::ContentSettingPatternSource() |
86 : setting(CONTENT_SETTING_DEFAULT), incognito(false) { | 87 : setting(CONTENT_SETTING_DEFAULT), incognito(false) { |
87 } | 88 } |
88 | 89 |
89 RendererContentSettingRules::RendererContentSettingRules() {} | 90 RendererContentSettingRules::RendererContentSettingRules() {} |
90 | 91 |
91 RendererContentSettingRules::~RendererContentSettingRules() {} | 92 RendererContentSettingRules::~RendererContentSettingRules() {} |
OLD | NEW |