Chromium Code Reviews| Index: chrome/browser/extensions/extension_content_settings_store.h | 
| diff --git a/chrome/browser/extensions/extension_content_settings_store.h b/chrome/browser/extensions/extension_content_settings_store.h | 
| index b2672686279874be75d6a0a6b14c27537f01ff9a..8db0e47d66d8f8db8b64a66c89277736713bf65b 100644 | 
| --- a/chrome/browser/extensions/extension_content_settings_store.h | 
| +++ b/chrome/browser/extensions/extension_content_settings_store.h | 
| @@ -16,6 +16,7 @@ | 
| #include "base/tuple.h" | 
| #include "chrome/browser/content_settings/content_settings_pattern.h" | 
| #include "chrome/browser/content_settings/content_settings_provider.h" | 
| +#include "chrome/browser/extensions/extension_prefs_scope.h" | 
| #include "chrome/common/content_settings.h" | 
| #include "googleurl/src/gurl.h" | 
| @@ -60,7 +61,7 @@ class ExtensionContentSettingsStore { | 
| ContentSettingsType type, | 
| const content_settings::ResourceIdentifier& identifier, | 
| ContentSetting setting, | 
| - bool incognito); | 
| + extension_prefs_scope::Scope scope); | 
| ContentSetting GetEffectiveContentSetting( | 
| const GURL& embedded_url, | 
| @@ -69,6 +70,10 @@ class ExtensionContentSettingsStore { | 
| const content_settings::ResourceIdentifier& identifier, | 
| bool incognito) const; | 
| + // Clears all contents settings set by the extension |ext_id|. | 
| + void ClearContentSettingsForExtension(const std::string& ext_id, | 
| + extension_prefs_scope::Scope scope); | 
| + | 
| // Returns a list of all content setting rules for the content type |type| | 
| // and the resource identifier (if specified and the content type uses | 
| // resource identifiers). | 
| @@ -81,12 +86,14 @@ class ExtensionContentSettingsStore { | 
| // Serializes all content settings set by the extension with ID |extension_id| | 
| // and returns them as a ListValue. The caller takes ownership of the returned | 
| // value. | 
| - ListValue* GetSettingsForExtension(const std::string& extension_id) const; | 
| + ListValue* GetSettingsForExtension(const std::string& extension_id, | 
| + extension_prefs_scope::Scope scope) const; | 
| // Deserializes content settings rules from |list| and applies them as set by | 
| // the extension with ID |extension_id|. | 
| void SetExtensionContentSettingsFromList(const std::string& extension_id, | 
| - const ListValue* dict); | 
| + const ListValue* dict, | 
| 
 
battre
2011/06/03 18:48:36
nit: |dict| -> |list| (see line 92)
 
Bernhard Bauer
2011/06/03 20:34:28
Done.
 
 | 
| + extension_prefs_scope::Scope scope); | 
| // ////////////////////////////////////////////////////////////////////////// | 
| @@ -137,11 +144,16 @@ class ExtensionContentSettingsStore { | 
| ContentSettingSpecList* GetContentSettingSpecList( | 
| const std::string& ext_id, | 
| - bool incognito); | 
| + extension_prefs_scope::Scope scope); | 
| const ContentSettingSpecList* GetContentSettingSpecList( | 
| const std::string& ext_id, | 
| - bool incognito) const; | 
| + extension_prefs_scope::Scope scope) const; | 
| + | 
| + static void AddRules(ContentSettingsType type, | 
| 
 
battre
2011/06/03 18:48:36
Add a comment?
 
Bernhard Bauer
2011/06/03 20:34:28
Done.
 
 | 
| + const content_settings::ResourceIdentifier& identifier, | 
| + content_settings::ProviderInterface::Rules* rules, | 
| + const ContentSettingSpecList* setting_spec_list); | 
| 
 
battre
2011/06/03 18:48:36
Order of parameters: You search for a match of |ty
 
Bernhard Bauer
2011/06/03 20:34:28
Good idea. Done.
 
 | 
| void NotifyOfContentSettingChanged(const std::string& extension_id, | 
| bool incognito); |