| OLD | NEW |
| 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/chromeos/login/login_display_host_impl.h" | 5 #include "chrome/browser/chromeos/login/login_display_host_impl.h" |
| 6 | 6 |
| 7 #include <vector> | 7 #include <vector> |
| 8 | 8 |
| 9 #include "ash/audio/sounds.h" | 9 #include "ash/audio/sounds.h" |
| 10 #include "ash/desktop_background/desktop_background_controller.h" | 10 #include "ash/desktop_background/desktop_background_controller.h" |
| (...skipping 1037 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1048 manager->SetInputMethodLoginDefault(); | 1048 manager->SetInputMethodLoginDefault(); |
| 1049 | 1049 |
| 1050 PrefService* prefs = g_browser_process->local_state(); | 1050 PrefService* prefs = g_browser_process->local_state(); |
| 1051 // Apply owner preferences for tap-to-click and mouse buttons swap for | 1051 // Apply owner preferences for tap-to-click and mouse buttons swap for |
| 1052 // login screen. | 1052 // login screen. |
| 1053 system::InputDeviceSettings::Get()->SetPrimaryButtonRight( | 1053 system::InputDeviceSettings::Get()->SetPrimaryButtonRight( |
| 1054 prefs->GetBoolean(prefs::kOwnerPrimaryMouseButtonRight)); | 1054 prefs->GetBoolean(prefs::kOwnerPrimaryMouseButtonRight)); |
| 1055 system::InputDeviceSettings::Get()->SetTapToClick( | 1055 system::InputDeviceSettings::Get()->SetTapToClick( |
| 1056 prefs->GetBoolean(prefs::kOwnerTapToClickEnabled)); | 1056 prefs->GetBoolean(prefs::kOwnerTapToClickEnabled)); |
| 1057 } | 1057 } |
| 1058 system::InputDeviceSettings::Get()->SetNaturalScroll( | 1058 |
| 1059 CommandLine::ForCurrentProcess()->HasSwitch( | 1059 ui::SetNaturalScroll(CommandLine::ForCurrentProcess()->HasSwitch( |
| 1060 switches::kNaturalScrollDefault)); | 1060 switches::kNaturalScrollDefault)); |
| 1061 | 1061 |
| 1062 gfx::Rect screen_bounds(chromeos::CalculateScreenBounds(gfx::Size())); | 1062 gfx::Rect screen_bounds(chromeos::CalculateScreenBounds(gfx::Size())); |
| 1063 | 1063 |
| 1064 // Check whether we need to execute OOBE process. | 1064 // Check whether we need to execute OOBE process. |
| 1065 bool oobe_complete = chromeos::StartupUtils::IsOobeCompleted(); | 1065 bool oobe_complete = chromeos::StartupUtils::IsOobeCompleted(); |
| 1066 if (!oobe_complete) { | 1066 if (!oobe_complete) { |
| 1067 LoginState::Get()->SetLoggedInState( | 1067 LoginState::Get()->SetLoggedInState( |
| 1068 LoginState::LOGGED_IN_OOBE, LoginState::LOGGED_IN_USER_NONE); | 1068 LoginState::LOGGED_IN_OOBE, LoginState::LOGGED_IN_USER_NONE); |
| 1069 } else { | 1069 } else { |
| 1070 LoginState::Get()->SetLoggedInState( | 1070 LoginState::Get()->SetLoggedInState( |
| (...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1163 scoped_ptr<locale_util::SwitchLanguageCallback> callback( | 1163 scoped_ptr<locale_util::SwitchLanguageCallback> callback( |
| 1164 new locale_util::SwitchLanguageCallback( | 1164 new locale_util::SwitchLanguageCallback( |
| 1165 base::Bind(&OnLanguageSwitchedCallback, base::Passed(data.Pass())))); | 1165 base::Bind(&OnLanguageSwitchedCallback, base::Passed(data.Pass())))); |
| 1166 | 1166 |
| 1167 // Load locale keyboards here. Hardware layout would be automatically enabled. | 1167 // Load locale keyboards here. Hardware layout would be automatically enabled. |
| 1168 locale_util::SwitchLanguage( | 1168 locale_util::SwitchLanguage( |
| 1169 locale, true, true /* login_layouts_only */, callback.Pass()); | 1169 locale, true, true /* login_layouts_only */, callback.Pass()); |
| 1170 } | 1170 } |
| 1171 | 1171 |
| 1172 } // namespace chromeos | 1172 } // namespace chromeos |
| OLD | NEW |