Chromium Code Reviews| Index: components/content_settings/core/browser/content_settings_info.cc |
| diff --git a/components/content_settings/core/browser/content_settings_info.cc b/components/content_settings/core/browser/content_settings_info.cc |
| index 01fee49a33bf9d1be57c190d346d4afa900dd8be..976fec211eccb73ddd825f18154671ff542be749 100644 |
| --- a/components/content_settings/core/browser/content_settings_info.cc |
| +++ b/components/content_settings/core/browser/content_settings_info.cc |
| @@ -4,14 +4,22 @@ |
| #include "components/content_settings/core/browser/content_settings_info.h" |
| +#include "base/stl_util.h" |
| + |
| namespace content_settings { |
| ContentSettingsInfo::ContentSettingsInfo( |
| const WebsiteSettingsInfo* website_settings_info, |
| - const std::vector<std::string>& whitelisted_schemes) |
| + const std::vector<std::string>& whitelisted_schemes, |
| + const std::set<ContentSetting>& valid_settings) |
| : website_settings_info_(website_settings_info), |
| - whitelisted_schemes_(whitelisted_schemes) {} |
| + whitelisted_schemes_(whitelisted_schemes), |
| + valid_settings_(valid_settings) {} |
| ContentSettingsInfo::~ContentSettingsInfo() {} |
| +bool ContentSettingsInfo::IsSettingValid(ContentSetting setting) const { |
|
engedy
2015/10/06 08:53:25
Either this, or something up the call hierarchy st
raymes
2015/10/12 00:03:12
Good catch. I agree with what you're saying in the
|
| + return ContainsKey(valid_settings_, setting); |
| +} |
| + |
| } // namespace content_settings |