| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/ui/webui/options/create_profile_handler.h" | 5 #include "chrome/browser/ui/webui/options/create_profile_handler.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/command_line.h" | |
| 9 #include "base/files/file_path.h" | 8 #include "base/files/file_path.h" |
| 10 #include "base/metrics/histogram.h" | 9 #include "base/metrics/histogram.h" |
| 11 #include "base/prefs/pref_service.h" | 10 #include "base/prefs/pref_service.h" |
| 12 #include "base/value_conversions.h" | 11 #include "base/value_conversions.h" |
| 13 #include "base/values.h" | 12 #include "base/values.h" |
| 14 #include "chrome/browser/browser_process.h" | 13 #include "chrome/browser/browser_process.h" |
| 15 #include "chrome/browser/managed_mode/managed_user_registration_utility.h" | 14 #include "chrome/browser/managed_mode/managed_user_registration_utility.h" |
| 16 #include "chrome/browser/managed_mode/managed_user_service.h" | 15 #include "chrome/browser/managed_mode/managed_user_service.h" |
| 17 #include "chrome/browser/managed_mode/managed_user_service_factory.h" | 16 #include "chrome/browser/managed_mode/managed_user_service_factory.h" |
| 18 #include "chrome/browser/managed_mode/managed_user_sync_service.h" | 17 #include "chrome/browser/managed_mode/managed_user_sync_service.h" |
| (...skipping 402 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 421 const ProfileInfoCache& cache = | 420 const ProfileInfoCache& cache = |
| 422 g_browser_process->profile_manager()->GetProfileInfoCache(); | 421 g_browser_process->profile_manager()->GetProfileInfoCache(); |
| 423 for (size_t i = 0; i < cache.GetNumberOfProfiles(); ++i) { | 422 for (size_t i = 0; i < cache.GetNumberOfProfiles(); ++i) { |
| 424 if (existing_managed_user_id == cache.GetManagedUserIdOfProfileAtIndex(i)) | 423 if (existing_managed_user_id == cache.GetManagedUserIdOfProfileAtIndex(i)) |
| 425 return false; | 424 return false; |
| 426 } | 425 } |
| 427 return true; | 426 return true; |
| 428 } | 427 } |
| 429 | 428 |
| 430 } // namespace options | 429 } // namespace options |
| OLD | NEW |