Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(11)

Side by Side Diff: chrome/browser/prefs/chrome_pref_service_factory.cc

Issue 348433004: Prune all safe browsing incidents when already reported. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: more test cleanups Created 6 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/browser/profiles/profile.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/prefs/chrome_pref_service_factory.h" 5 #include "chrome/browser/prefs/chrome_pref_service_factory.h"
6 6
7 #include <string> 7 #include <string>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after
165 // pref which is required for it to be visible when queried via the 165 // pref which is required for it to be visible when queried via the
166 // SegregatedPrefStore. This is because it's written directly in the 166 // SegregatedPrefStore. This is because it's written directly in the
167 // protected JsonPrefStore by that store's PrefHashFilter if there was 167 // protected JsonPrefStore by that store's PrefHashFilter if there was
168 // a reset in FilterOnLoad and SegregatedPrefStore will not look for it 168 // a reset in FilterOnLoad and SegregatedPrefStore will not look for it
169 // in the protected JsonPrefStore unless it's declared as a protected 169 // in the protected JsonPrefStore unless it's declared as a protected
170 // preference here. 170 // preference here.
171 15, prefs::kPreferenceResetTime, 171 15, prefs::kPreferenceResetTime,
172 PrefHashFilter::ENFORCE_ON_LOAD, 172 PrefHashFilter::ENFORCE_ON_LOAD,
173 PrefHashFilter::TRACKING_STRATEGY_ATOMIC 173 PrefHashFilter::TRACKING_STRATEGY_ATOMIC
174 }, 174 },
175 {
176 16, prefs::kSafeBrowsingIncidentReportSent,
177 PrefHashFilter::ENFORCE_ON_LOAD,
178 PrefHashFilter::TRACKING_STRATEGY_ATOMIC
179 },
175 }; 180 };
176 181
177 // The count of tracked preferences IDs across all platforms. 182 // The count of tracked preferences IDs across all platforms.
178 const size_t kTrackedPrefsReportingIDsCount = 16; 183 const size_t kTrackedPrefsReportingIDsCount = 17;
179 COMPILE_ASSERT(kTrackedPrefsReportingIDsCount >= arraysize(kTrackedPrefs), 184 COMPILE_ASSERT(kTrackedPrefsReportingIDsCount >= arraysize(kTrackedPrefs),
180 need_to_increment_ids_count); 185 need_to_increment_ids_count);
181 186
182 // Each group enforces a superset of the protection provided by the previous 187 // Each group enforces a superset of the protection provided by the previous
183 // one. 188 // one.
184 enum SettingsEnforcementGroup { 189 enum SettingsEnforcementGroup {
185 GROUP_NO_ENFORCEMENT, 190 GROUP_NO_ENFORCEMENT,
186 // Enforce protected settings on profile loads. 191 // Enforce protected settings on profile loads.
187 GROUP_ENFORCE_ALWAYS, 192 GROUP_ENFORCE_ALWAYS,
188 // Also enforce extension default search. 193 // Also enforce extension default search.
(...skipping 291 matching lines...) Expand 10 before | Expand all | Expand 10 after
480 485
481 void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry) { 486 void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry) {
482 ProfilePrefStoreManager::RegisterProfilePrefs(registry); 487 ProfilePrefStoreManager::RegisterProfilePrefs(registry);
483 } 488 }
484 489
485 void RegisterPrefs(PrefRegistrySimple* registry) { 490 void RegisterPrefs(PrefRegistrySimple* registry) {
486 ProfilePrefStoreManager::RegisterPrefs(registry); 491 ProfilePrefStoreManager::RegisterPrefs(registry);
487 } 492 }
488 493
489 } // namespace chrome_prefs 494 } // namespace chrome_prefs
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/profiles/profile.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698