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

Unified Diff: components/content_settings/core/browser/host_content_settings_map.h

Issue 2812113004: Write last_modified date to Content Settings in the PrefProvider (Closed)
Patch Set: Fix Android compilation Created 3 years, 8 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: components/content_settings/core/browser/host_content_settings_map.h
diff --git a/components/content_settings/core/browser/host_content_settings_map.h b/components/content_settings/core/browser/host_content_settings_map.h
index eadf365cfbd2aeea7914d113f75d79a4d1764d29..68a69b6787e21df12f3d5abc98ef29dd65dd85f5 100644
--- a/components/content_settings/core/browser/host_content_settings_map.h
+++ b/components/content_settings/core/browser/host_content_settings_map.h
@@ -48,6 +48,14 @@ class PrefRegistrySyncable;
class HostContentSettingsMap : public content_settings::Observer,
public RefcountedKeyedService {
public:
+// Whether ContentSettings in the PrefProvider will store a last_modified
+// timestamp.
+#if defined(OS_ANDROID)
msramek 2017/04/19 10:49:16 To answer your question - I'd prefer if this was g
dullweber 2017/04/19 15:02:45 Done.
+ static const bool kStoreLastModified = true;
+#else
+ static const bool kStoreLastModified = false;
+#endif
+
enum ProviderType {
// EXTENSION names is a layering violation when this class will move to
// components.
@@ -221,9 +229,9 @@ class HostContentSettingsMap : public content_settings::Observer,
// Otherwise, it only deletes exceptions matched by |pattern_predicate|.
void ClearSettingsForOneTypeWithPredicate(
ContentSettingsType content_type,
- const base::Callback<bool(
- const ContentSettingsPattern& primary_pattern,
- const ContentSettingsPattern& secondary_pattern)>& pattern_predicate);
+ const base::Callback<bool(const ContentSettingsPattern& primary_pattern,
+ const ContentSettingsPattern& secondary_pattern,
+ base::Time last_modified)>& pattern_predicate);
static bool IsDefaultSettingAllowedForType(ContentSetting setting,
ContentSettingsType content_type);

Powered by Google App Engine
This is Rietveld 408576698