| 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 #include "chrome/browser/content_settings/content_settings_pref_provider.h" | 5 #include "chrome/browser/content_settings/content_settings_pref_provider.h" |
| 6 | 6 |
| 7 #include <map> | 7 #include <map> |
| 8 #include <string> | 8 #include <string> |
| 9 #include <utility> | 9 #include <utility> |
| 10 | 10 |
| (...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 65 | 65 |
| 66 } // namespace | 66 } // namespace |
| 67 | 67 |
| 68 namespace content_settings { | 68 namespace content_settings { |
| 69 | 69 |
| 70 // //////////////////////////////////////////////////////////////////////////// | 70 // //////////////////////////////////////////////////////////////////////////// |
| 71 // PrefProvider: | 71 // PrefProvider: |
| 72 // | 72 // |
| 73 | 73 |
| 74 // static | 74 // static |
| 75 void PrefProvider::RegisterUserPrefs( | 75 void PrefProvider::RegisterProfilePrefs( |
| 76 user_prefs::PrefRegistrySyncable* registry) { | 76 user_prefs::PrefRegistrySyncable* registry) { |
| 77 registry->RegisterIntegerPref( | 77 registry->RegisterIntegerPref( |
| 78 prefs::kContentSettingsVersion, | 78 prefs::kContentSettingsVersion, |
| 79 ContentSettingsPattern::kContentSettingsPatternVersion, | 79 ContentSettingsPattern::kContentSettingsPatternVersion, |
| 80 user_prefs::PrefRegistrySyncable::UNSYNCABLE_PREF); | 80 user_prefs::PrefRegistrySyncable::UNSYNCABLE_PREF); |
| 81 registry->RegisterDictionaryPref( | 81 registry->RegisterDictionaryPref( |
| 82 prefs::kContentSettingsPatternPairs, | 82 prefs::kContentSettingsPatternPairs, |
| 83 user_prefs::PrefRegistrySyncable::SYNCABLE_PREF); | 83 user_prefs::PrefRegistrySyncable::SYNCABLE_PREF); |
| 84 } | 84 } |
| 85 | 85 |
| (...skipping 479 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 565 | 565 |
| 566 void PrefProvider::AssertLockNotHeld() const { | 566 void PrefProvider::AssertLockNotHeld() const { |
| 567 #if !defined(NDEBUG) | 567 #if !defined(NDEBUG) |
| 568 // |Lock::Acquire()| will assert if the lock is held by this thread. | 568 // |Lock::Acquire()| will assert if the lock is held by this thread. |
| 569 lock_.Acquire(); | 569 lock_.Acquire(); |
| 570 lock_.Release(); | 570 lock_.Release(); |
| 571 #endif | 571 #endif |
| 572 } | 572 } |
| 573 | 573 |
| 574 } // namespace content_settings | 574 } // namespace content_settings |
| OLD | NEW |