| 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/chromeos/app_mode/kiosk_app_manager.h" | 5 #include "chrome/browser/chromeos/app_mode/kiosk_app_manager.h" |
| 6 | 6 |
| 7 #include <map> | 7 #include <map> |
| 8 #include <set> | 8 #include <set> |
| 9 | 9 |
| 10 #include "base/bind.h" | 10 #include "base/bind.h" |
| 11 #include "base/chromeos/chromeos_version.h" | 11 #include "base/chromeos/chromeos_version.h" |
| 12 #include "base/logging.h" | 12 #include "base/logging.h" |
| 13 #include "base/path_service.h" | 13 #include "base/path_service.h" |
| 14 #include "base/prefs/pref_registry_simple.h" | 14 #include "base/prefs/pref_registry_simple.h" |
| 15 #include "base/prefs/pref_service.h" | 15 #include "base/prefs/pref_service.h" |
| 16 #include "base/stl_util.h" | 16 #include "base/stl_util.h" |
| 17 #include "chrome/browser/browser_process.h" | 17 #include "chrome/browser/browser_process.h" |
| 18 #include "chrome/browser/chrome_notification_types.h" |
| 18 #include "chrome/browser/chromeos/app_mode/kiosk_app_data.h" | 19 #include "chrome/browser/chromeos/app_mode/kiosk_app_data.h" |
| 19 #include "chrome/browser/chromeos/app_mode/kiosk_app_manager.h" | 20 #include "chrome/browser/chromeos/app_mode/kiosk_app_manager.h" |
| 20 #include "chrome/browser/chromeos/app_mode/kiosk_app_manager_observer.h" | 21 #include "chrome/browser/chromeos/app_mode/kiosk_app_manager_observer.h" |
| 21 #include "chrome/browser/chromeos/login/user_manager.h" | 22 #include "chrome/browser/chromeos/login/user_manager.h" |
| 22 #include "chrome/browser/chromeos/policy/device_local_account.h" | 23 #include "chrome/browser/chromeos/policy/device_local_account.h" |
| 23 #include "chrome/browser/chromeos/settings/cros_settings.h" | 24 #include "chrome/browser/chromeos/settings/cros_settings.h" |
| 24 #include "chrome/browser/chromeos/settings/cros_settings_names.h" | 25 #include "chrome/browser/chromeos/settings/cros_settings_names.h" |
| 25 #include "chrome/browser/chromeos/settings/owner_key_util.h" | 26 #include "chrome/browser/chromeos/settings/owner_key_util.h" |
| 26 #include "chrome/browser/policy/browser_policy_connector.h" | 27 #include "chrome/browser/policy/browser_policy_connector.h" |
| 27 #include "chrome/browser/prefs/scoped_user_pref_update.h" | 28 #include "chrome/browser/prefs/scoped_user_pref_update.h" |
| 28 #include "chrome/common/chrome_notification_types.h" | |
| 29 #include "chrome/common/chrome_paths.h" | 29 #include "chrome/common/chrome_paths.h" |
| 30 #include "chromeos/cryptohome/async_method_caller.h" | 30 #include "chromeos/cryptohome/async_method_caller.h" |
| 31 #include "chromeos/cryptohome/cryptohome_library.h" | 31 #include "chromeos/cryptohome/cryptohome_library.h" |
| 32 #include "content/public/browser/browser_thread.h" | 32 #include "content/public/browser/browser_thread.h" |
| 33 | 33 |
| 34 namespace chromeos { | 34 namespace chromeos { |
| 35 | 35 |
| 36 namespace { | 36 namespace { |
| 37 | 37 |
| 38 // Domain that is used for kiosk-app account IDs. | 38 // Domain that is used for kiosk-app account IDs. |
| (...skipping 391 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 430 | 430 |
| 431 void KioskAppManager::SetAutoLoginState(AutoLoginState state) { | 431 void KioskAppManager::SetAutoLoginState(AutoLoginState state) { |
| 432 PrefService* prefs = g_browser_process->local_state(); | 432 PrefService* prefs = g_browser_process->local_state(); |
| 433 DictionaryPrefUpdate dict_update(prefs, | 433 DictionaryPrefUpdate dict_update(prefs, |
| 434 KioskAppManager::kKioskDictionaryName); | 434 KioskAppManager::kKioskDictionaryName); |
| 435 dict_update->SetInteger(kKeyAutoLoginState, state); | 435 dict_update->SetInteger(kKeyAutoLoginState, state); |
| 436 prefs->CommitPendingWrite(); | 436 prefs->CommitPendingWrite(); |
| 437 } | 437 } |
| 438 | 438 |
| 439 } // namespace chromeos | 439 } // namespace chromeos |
| OLD | NEW |