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 // Maps hostnames to custom content settings. Written on the UI thread and read | 5 // Maps hostnames to custom content settings. Written on the UI thread and read |
6 // on any thread. One instance per profile. | 6 // on any thread. One instance per profile. |
7 | 7 |
8 #ifndef CHROME_BROWSER_CONTENT_SETTINGS_HOST_CONTENT_SETTINGS_MAP_H_ | 8 #ifndef CHROME_BROWSER_CONTENT_SETTINGS_HOST_CONTENT_SETTINGS_MAP_H_ |
9 #define CHROME_BROWSER_CONTENT_SETTINGS_HOST_CONTENT_SETTINGS_MAP_H_ | 9 #define CHROME_BROWSER_CONTENT_SETTINGS_HOST_CONTENT_SETTINGS_MAP_H_ |
10 #pragma once | 10 #pragma once |
(...skipping 199 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
210 const std::string& resource_identifier, | 210 const std::string& resource_identifier, |
211 ContentSettingsForOneType* settings, | 211 ContentSettingsForOneType* settings, |
212 bool incognito) const; | 212 bool incognito) const; |
213 | 213 |
214 // Weak; owned by the Profile. | 214 // Weak; owned by the Profile. |
215 PrefService* prefs_; | 215 PrefService* prefs_; |
216 | 216 |
217 // Whether this settings map is for an OTR session. | 217 // Whether this settings map is for an OTR session. |
218 bool is_off_the_record_; | 218 bool is_off_the_record_; |
219 | 219 |
220 // Whether we are currently updating preferences, this is used to ignore | |
221 // notifications from the preferences service that we triggered ourself. | |
222 bool updating_preferences_; | |
223 | |
224 // Content setting providers. | 220 // Content setting providers. |
225 ProviderMap content_settings_providers_; | 221 ProviderMap content_settings_providers_; |
226 | 222 |
227 // Used around accesses to the following objects to guarantee thread safety. | 223 // Used around accesses to the following objects to guarantee thread safety. |
228 mutable base::Lock lock_; | 224 mutable base::Lock lock_; |
229 | 225 |
230 DISALLOW_COPY_AND_ASSIGN(HostContentSettingsMap); | 226 DISALLOW_COPY_AND_ASSIGN(HostContentSettingsMap); |
231 }; | 227 }; |
232 | 228 |
233 #endif // CHROME_BROWSER_CONTENT_SETTINGS_HOST_CONTENT_SETTINGS_MAP_H_ | 229 #endif // CHROME_BROWSER_CONTENT_SETTINGS_HOST_CONTENT_SETTINGS_MAP_H_ |
OLD | NEW |