| Index: chrome/browser/content_settings/content_settings_pref_provider.h
|
| diff --git a/chrome/browser/content_settings/content_settings_pref_provider.h b/chrome/browser/content_settings/content_settings_pref_provider.h
|
| index 9d8a2bcba85cd040601ca7c616b3483b739f0dbd..8a8c17086a18f4437c37e2946ac28e3db69f311c 100644
|
| --- a/chrome/browser/content_settings/content_settings_pref_provider.h
|
| +++ b/chrome/browser/content_settings/content_settings_pref_provider.h
|
| @@ -19,6 +19,7 @@
|
| class PrefService;
|
|
|
| namespace base {
|
| +class Clock;
|
| class DictionaryValue;
|
| }
|
|
|
| @@ -55,6 +56,18 @@ class PrefProvider : public ObservableProvider {
|
|
|
| virtual void ShutdownOnUIThread() OVERRIDE;
|
|
|
| + // Records the last time the given pattern has used a certain content setting.
|
| + virtual void UpdateLastUsage(const ContentSettingsPattern& primary_pattern,
|
| + const ContentSettingsPattern& secondary_pattern,
|
| + ContentSettingsType content_type);
|
| +
|
| + base::Time GetLastUsage(const ContentSettingsPattern& primary_pattern,
|
| + const ContentSettingsPattern& secondary_pattern,
|
| + ContentSettingsType content_type);
|
| +
|
| + // Gains ownership of |clock|.
|
| + void SetClockForTesting(base::Clock* clock);
|
| +
|
| private:
|
| friend class DeadlockCheckerThread; // For testing.
|
| // Reads all content settings exceptions from the preference and load them
|
| @@ -90,6 +103,9 @@ class PrefProvider : public ObservableProvider {
|
| // Weak; owned by the Profile and reset in ShutdownOnUIThread.
|
| PrefService* prefs_;
|
|
|
| + // Can be set for testing.
|
| + scoped_ptr<base::Clock> clock_;
|
| +
|
| bool is_incognito_;
|
|
|
| PrefChangeRegistrar pref_change_registrar_;
|
|
|