OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef CHROME_BROWSER_CONTENT_SETTINGS_CONTENT_SETTINGS_PREF_PROVIDER_H_ | 5 #ifndef CHROME_BROWSER_CONTENT_SETTINGS_CONTENT_SETTINGS_PREF_PROVIDER_H_ |
6 #define CHROME_BROWSER_CONTENT_SETTINGS_CONTENT_SETTINGS_PREF_PROVIDER_H_ | 6 #define CHROME_BROWSER_CONTENT_SETTINGS_CONTENT_SETTINGS_PREF_PROVIDER_H_ |
7 | 7 |
8 // A content settings provider that takes its settings out of the pref service. | 8 // A content settings provider that takes its settings out of the pref service. |
9 | 9 |
10 #include <vector> | 10 #include <vector> |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
49 const ContentSettingsPattern& secondary_pattern, | 49 const ContentSettingsPattern& secondary_pattern, |
50 ContentSettingsType content_type, | 50 ContentSettingsType content_type, |
51 const ResourceIdentifier& resource_identifier, | 51 const ResourceIdentifier& resource_identifier, |
52 base::Value* value) OVERRIDE; | 52 base::Value* value) OVERRIDE; |
53 | 53 |
54 virtual void ClearAllContentSettingsRules( | 54 virtual void ClearAllContentSettingsRules( |
55 ContentSettingsType content_type) OVERRIDE; | 55 ContentSettingsType content_type) OVERRIDE; |
56 | 56 |
57 virtual void ShutdownOnUIThread() OVERRIDE; | 57 virtual void ShutdownOnUIThread() OVERRIDE; |
58 | 58 |
| 59 virtual std::string GetProviderName() const OVERRIDE; |
| 60 |
| 61 virtual SettingSource GetSettingSource() const OVERRIDE; |
| 62 |
59 // Records the last time the given pattern has used a certain content setting. | 63 // Records the last time the given pattern has used a certain content setting. |
60 void UpdateLastUsage(const ContentSettingsPattern& primary_pattern, | 64 void UpdateLastUsage(const ContentSettingsPattern& primary_pattern, |
61 const ContentSettingsPattern& secondary_pattern, | 65 const ContentSettingsPattern& secondary_pattern, |
62 ContentSettingsType content_type); | 66 ContentSettingsType content_type); |
63 | 67 |
64 base::Time GetLastUsage(const ContentSettingsPattern& primary_pattern, | 68 base::Time GetLastUsage(const ContentSettingsPattern& primary_pattern, |
65 const ContentSettingsPattern& secondary_pattern, | 69 const ContentSettingsPattern& secondary_pattern, |
66 ContentSettingsType content_type); | 70 ContentSettingsType content_type); |
67 | 71 |
68 // Gains ownership of |clock|. | 72 // Gains ownership of |clock|. |
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
120 | 124 |
121 // Used around accesses to the value map objects to guarantee thread safety. | 125 // Used around accesses to the value map objects to guarantee thread safety. |
122 mutable base::Lock lock_; | 126 mutable base::Lock lock_; |
123 | 127 |
124 DISALLOW_COPY_AND_ASSIGN(PrefProvider); | 128 DISALLOW_COPY_AND_ASSIGN(PrefProvider); |
125 }; | 129 }; |
126 | 130 |
127 } // namespace content_settings | 131 } // namespace content_settings |
128 | 132 |
129 #endif // CHROME_BROWSER_CONTENT_SETTINGS_CONTENT_SETTINGS_PREF_PROVIDER_H_ | 133 #endif // CHROME_BROWSER_CONTENT_SETTINGS_CONTENT_SETTINGS_PREF_PROVIDER_H_ |
OLD | NEW |