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

Unified Diff: chrome/browser/content_settings/content_settings_provider.h

Issue 7275018: Make ExtensionContentSettingsStore refcounted. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: review Created 9 years, 5 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/content_settings/content_settings_provider.h
diff --git a/chrome/browser/content_settings/content_settings_provider.h b/chrome/browser/content_settings/content_settings_provider.h
index 1056ea2885b6cf8e7ccc5a62d3808003c9261ac1..0d6abb4b2e6a00c382f2f98cb1344ff60274458b 100644
--- a/chrome/browser/content_settings/content_settings_provider.h
+++ b/chrome/browser/content_settings/content_settings_provider.h
@@ -81,7 +81,8 @@ class ProviderInterface {
// require a resource identifier to be specified, the |resource_identifier|
// must be non-empty.
//
- // This should only be called on the UI thread.
+ // This should only be called on the UI thread, and not after
+ // ShutdownOnUIThread has been called.
virtual void SetContentSetting(
const ContentSettingsPattern& primary_pattern,
const ContentSettingsPattern& secondary_pattern,
@@ -108,14 +109,22 @@ class ProviderInterface {
// identifier all content settings for any resource identifieres of the given
// |content_type| will be reset to CONTENT_SETTING_DEFAULT.
//
- // This should only be called on the UI thread.
+ // This should only be called on the UI thread, and not after
+ // ShutdownOnUIThread has been called.
virtual void ClearAllContentSettingsRules(
ContentSettingsType content_type) = 0;
// Resets all content settings to CONTENT_SETTINGS_DEFAULT.
//
- // This should only be called on the UI thread.
+ // This should only be called on the UI thread, and not after
+ // ShutdownOnUIThread has been called.
virtual void ResetToDefaults() = 0;
+
+ // Detaches the Provider from all Profile-related objects like PrefService.
+ // This methods needs to be called before destroying the Profile.
+ // Afterwards, none of the methods above that should only be called on the UI
+ // thread should be called anymore.
+ virtual void ShutdownOnUIThread() {}
};
} // namespace content_settings

Powered by Google App Engine
This is Rietveld 408576698