| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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/chromeos/login/signin_screen_handler.h" | 5 #include "chrome/browser/ui/webui/chromeos/login/signin_screen_handler.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include <algorithm> | 9 #include <algorithm> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 68 #include "chrome/browser/ui/webui/chromeos/login/native_window_delegate.h" | 68 #include "chrome/browser/ui/webui/chromeos/login/native_window_delegate.h" |
| 69 #include "chrome/browser/ui/webui/chromeos/login/network_state_informer.h" | 69 #include "chrome/browser/ui/webui/chromeos/login/network_state_informer.h" |
| 70 #include "chrome/common/channel_info.h" | 70 #include "chrome/common/channel_info.h" |
| 71 #include "chrome/common/pref_names.h" | 71 #include "chrome/common/pref_names.h" |
| 72 #include "chrome/common/url_constants.h" | 72 #include "chrome/common/url_constants.h" |
| 73 #include "chrome/grit/chromium_strings.h" | 73 #include "chrome/grit/chromium_strings.h" |
| 74 #include "chrome/grit/generated_resources.h" | 74 #include "chrome/grit/generated_resources.h" |
| 75 #include "chromeos/chromeos_switches.h" | 75 #include "chromeos/chromeos_switches.h" |
| 76 #include "chromeos/dbus/dbus_thread_manager.h" | 76 #include "chromeos/dbus/dbus_thread_manager.h" |
| 77 #include "chromeos/dbus/power_manager_client.h" | 77 #include "chromeos/dbus/power_manager_client.h" |
| 78 #include "chromeos/dbus/upstart_client.h" | |
| 79 #include "chromeos/login/auth/key.h" | 78 #include "chromeos/login/auth/key.h" |
| 80 #include "chromeos/login/auth/user_context.h" | 79 #include "chromeos/login/auth/user_context.h" |
| 81 #include "chromeos/network/network_state.h" | 80 #include "chromeos/network/network_state.h" |
| 82 #include "chromeos/network/network_state_handler.h" | 81 #include "chromeos/network/network_state_handler.h" |
| 83 #include "components/login/localized_values_builder.h" | 82 #include "components/login/localized_values_builder.h" |
| 84 #include "components/prefs/pref_registry_simple.h" | 83 #include "components/prefs/pref_registry_simple.h" |
| 85 #include "components/prefs/pref_service.h" | 84 #include "components/prefs/pref_service.h" |
| 86 #include "components/prefs/scoped_user_pref_update.h" | 85 #include "components/prefs/scoped_user_pref_update.h" |
| 87 #include "components/proximity_auth/screenlock_bridge.h" | 86 #include "components/proximity_auth/screenlock_bridge.h" |
| 88 #include "components/strings/grit/components_strings.h" | 87 #include "components/strings/grit/components_strings.h" |
| (...skipping 1167 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1256 | 1255 |
| 1257 void SigninScreenHandler::HandleToggleEnrollmentAd() { | 1256 void SigninScreenHandler::HandleToggleEnrollmentAd() { |
| 1258 // TODO(rsorokin): Cleanup enrollment flow for Active Directory. (see | 1257 // TODO(rsorokin): Cleanup enrollment flow for Active Directory. (see |
| 1259 // crbug.com/668491). | 1258 // crbug.com/668491). |
| 1260 if (chrome::GetChannel() == version_info::Channel::BETA || | 1259 if (chrome::GetChannel() == version_info::Channel::BETA || |
| 1261 chrome::GetChannel() == version_info::Channel::STABLE) { | 1260 chrome::GetChannel() == version_info::Channel::STABLE) { |
| 1262 return; | 1261 return; |
| 1263 } | 1262 } |
| 1264 base::CommandLine::ForCurrentProcess()->AppendSwitch( | 1263 base::CommandLine::ForCurrentProcess()->AppendSwitch( |
| 1265 chromeos::switches::kEnableAd); | 1264 chromeos::switches::kEnableAd); |
| 1266 chromeos::DBusThreadManager::Get() | |
| 1267 ->GetUpstartClient() | |
| 1268 ->StartAuthPolicyService(); | |
| 1269 } | 1265 } |
| 1270 | 1266 |
| 1271 void SigninScreenHandler::HandleToggleEnableDebuggingScreen() { | 1267 void SigninScreenHandler::HandleToggleEnableDebuggingScreen() { |
| 1272 if (delegate_) | 1268 if (delegate_) |
| 1273 delegate_->ShowEnableDebuggingScreen(); | 1269 delegate_->ShowEnableDebuggingScreen(); |
| 1274 } | 1270 } |
| 1275 | 1271 |
| 1276 void SigninScreenHandler::HandleToggleKioskEnableScreen() { | 1272 void SigninScreenHandler::HandleToggleKioskEnableScreen() { |
| 1277 policy::BrowserPolicyConnectorChromeOS* connector = | 1273 policy::BrowserPolicyConnectorChromeOS* connector = |
| 1278 g_browser_process->platform_part()->browser_policy_connector_chromeos(); | 1274 g_browser_process->platform_part()->browser_policy_connector_chromeos(); |
| (...skipping 330 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1609 if (focused_pod_account_id_) { | 1605 if (focused_pod_account_id_) { |
| 1610 std::string user_input_method = | 1606 std::string user_input_method = |
| 1611 GetUserLRUInputMethod(focused_pod_account_id_->GetUserEmail()); | 1607 GetUserLRUInputMethod(focused_pod_account_id_->GetUserEmail()); |
| 1612 EnforcePolicyInputMethods(user_input_method); | 1608 EnforcePolicyInputMethods(user_input_method); |
| 1613 } else { | 1609 } else { |
| 1614 EnforcePolicyInputMethods(std::string()); | 1610 EnforcePolicyInputMethods(std::string()); |
| 1615 } | 1611 } |
| 1616 } | 1612 } |
| 1617 | 1613 |
| 1618 } // namespace chromeos | 1614 } // namespace chromeos |
| OLD | NEW |