OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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/browser/content_settings_info.h" | 5 #include "components/content_settings/core/browser/content_settings_info.h" |
6 | 6 |
7 #include "base/stl_util.h" | 7 #include "base/stl_util.h" |
8 | 8 |
9 namespace content_settings { | 9 namespace content_settings { |
10 | 10 |
11 ContentSettingsInfo::ContentSettingsInfo( | 11 ContentSettingsInfo::ContentSettingsInfo( |
12 const WebsiteSettingsInfo* website_settings_info, | 12 const WebsiteSettingsInfo* website_settings_info, |
13 const std::vector<std::string>& whitelisted_schemes, | 13 const std::vector<std::string>& whitelisted_schemes, |
14 const std::set<ContentSetting>& valid_settings) | 14 const std::set<ContentSetting>& valid_settings, |
| 15 IncognitoBehavior incognito_behavior) |
15 : website_settings_info_(website_settings_info), | 16 : website_settings_info_(website_settings_info), |
16 whitelisted_schemes_(whitelisted_schemes), | 17 whitelisted_schemes_(whitelisted_schemes), |
17 valid_settings_(valid_settings) {} | 18 valid_settings_(valid_settings), |
| 19 incognito_behavior_(incognito_behavior) {} |
18 | 20 |
19 ContentSettingsInfo::~ContentSettingsInfo() {} | 21 ContentSettingsInfo::~ContentSettingsInfo() {} |
20 | 22 |
21 bool ContentSettingsInfo::IsSettingValid(ContentSetting setting) const { | 23 bool ContentSettingsInfo::IsSettingValid(ContentSetting setting) const { |
22 return ContainsKey(valid_settings_, setting); | 24 return ContainsKey(valid_settings_, setting); |
23 } | 25 } |
24 | 26 |
25 } // namespace content_settings | 27 } // namespace content_settings |
OLD | NEW |