Index: components/content_settings/core/browser/content_settings_pref.h |
diff --git a/components/content_settings/core/browser/content_settings_pref.h b/components/content_settings/core/browser/content_settings_pref.h |
index 77c6d031fb1c6256122669d3547924a5959a654a..356176c614cacba16b8bf7d8d5828c1ca55c2cbf 100644 |
--- a/components/content_settings/core/browser/content_settings_pref.h |
+++ b/components/content_settings/core/browser/content_settings_pref.h |
@@ -13,6 +13,7 @@ |
#include "base/macros.h" |
#include "base/synchronization/lock.h" |
#include "base/threading/thread_checker.h" |
+#include "base/time/time.h" |
#include "base/values.h" |
#include "components/content_settings/core/browser/content_settings_origin_identifier_value_map.h" |
#include "components/content_settings/core/browser/content_settings_provider.h" |
@@ -43,6 +44,7 @@ class ContentSettingsPref { |
PrefChangeRegistrar* registrar, |
const std::string& pref_name, |
bool incognito, |
+ bool store_last_modified, |
NotifyObserversCallback notify_callback); |
~ContentSettingsPref(); |
@@ -56,6 +58,12 @@ class ContentSettingsPref { |
const ResourceIdentifier& resource_identifier, |
base::Value* value); |
+ // Returns the |last_modified| date of a setting. |
+ base::Time GetWebsiteSettingLastModified( |
+ const ContentSettingsPattern& primary_pattern, |
+ const ContentSettingsPattern& secondary_pattern, |
+ const ResourceIdentifier& resource_identifier); |
+ |
void ClearPref(); |
void ClearAllContentSettingsRules(); |
@@ -77,11 +85,11 @@ class ContentSettingsPref { |
// value to the obsolete preference. When calling this function, |lock_| |
// should not be held, since this function will send out notifications of |
// preference changes. |
- void UpdatePref( |
- const ContentSettingsPattern& primary_pattern, |
- const ContentSettingsPattern& secondary_pattern, |
- const ResourceIdentifier& resource_identifier, |
- const base::Value* value); |
+ void UpdatePref(const ContentSettingsPattern& primary_pattern, |
+ const ContentSettingsPattern& secondary_pattern, |
+ const ResourceIdentifier& resource_identifier, |
+ const base::Time last_modified, |
+ const base::Value* value); |
static void CanonicalizeContentSettingsExceptions( |
base::DictionaryValue* all_settings_dictionary); |
@@ -105,6 +113,8 @@ class ContentSettingsPref { |
bool is_incognito_; |
+ bool store_last_modified_; |
+ |
// Whether we are currently updating preferences, this is used to ignore |
// notifications from the preferences service that we triggered ourself. |
bool updating_preferences_; |