OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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/supervised_user/supervised_user_whitelist_service.h" | 5 #include "chrome/browser/supervised_user/supervised_user_whitelist_service.h" |
6 | 6 |
| 7 #include <stddef.h> |
| 8 |
7 #include <string> | 9 #include <string> |
8 | 10 |
9 #include "base/command_line.h" | 11 #include "base/command_line.h" |
10 #include "base/files/file_path.h" | 12 #include "base/files/file_path.h" |
11 #include "base/metrics/histogram.h" | 13 #include "base/metrics/histogram.h" |
12 #include "base/metrics/user_metrics.h" | 14 #include "base/metrics/user_metrics.h" |
13 #include "base/metrics/user_metrics_action.h" | 15 #include "base/metrics/user_metrics_action.h" |
14 #include "base/prefs/pref_service.h" | 16 #include "base/prefs/pref_service.h" |
15 #include "base/prefs/scoped_user_pref_update.h" | 17 #include "base/prefs/scoped_user_pref_update.h" |
16 #include "base/strings/string_split.h" | 18 #include "base/strings/string_split.h" |
(...skipping 337 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
354 UMA_HISTOGRAM_TIMES("ManagedUsers.Whitelist.TotalLoadDuration", | 356 UMA_HISTOGRAM_TIMES("ManagedUsers.Whitelist.TotalLoadDuration", |
355 base::TimeTicks::Now() - start_time); | 357 base::TimeTicks::Now() - start_time); |
356 | 358 |
357 // If the whitelist has been unregistered in the mean time, ignore it. | 359 // If the whitelist has been unregistered in the mean time, ignore it. |
358 if (registered_whitelists_.count(id) == 0u) | 360 if (registered_whitelists_.count(id) == 0u) |
359 return; | 361 return; |
360 | 362 |
361 loaded_whitelists_[id] = whitelist; | 363 loaded_whitelists_[id] = whitelist; |
362 NotifyWhitelistsChanged(); | 364 NotifyWhitelistsChanged(); |
363 } | 365 } |
OLD | NEW |