Chromium Code Reviews| Index: chrome/browser/chromeos/login/ui/login_display_host_impl.cc |
| diff --git a/chrome/browser/chromeos/login/ui/login_display_host_impl.cc b/chrome/browser/chromeos/login/ui/login_display_host_impl.cc |
| index 5fdd82858cf7e32138336a01983bf68156665eca..0468c947cdfeb50159852162c4da753eb6843c47 100644 |
| --- a/chrome/browser/chromeos/login/ui/login_display_host_impl.cc |
| +++ b/chrome/browser/chromeos/login/ui/login_display_host_impl.cc |
| @@ -68,6 +68,7 @@ |
| #include "chromeos/ime/input_method_manager.h" |
| #include "chromeos/login/login_state.h" |
| #include "chromeos/settings/timezone_settings.h" |
| +#include "components/session_manager/core/session_manager.h" |
| #include "content/public/browser/notification_service.h" |
| #include "content/public/browser/notification_types.h" |
| #include "content/public/browser/render_frame_host.h" |
| @@ -1182,6 +1183,16 @@ void ShowLoginWizard(const std::string& first_screen_name) { |
| gfx::Rect screen_bounds(chromeos::CalculateScreenBounds(gfx::Size())); |
| + // Check whether we need to execute OOBE flow. |
| + bool oobe_complete = chromeos::StartupUtils::IsOobeCompleted(); |
|
oshima
2014/07/14 20:03:53
or
next_state = IsOobeCompleted() ? STATE_LOGIN_PR
Nikita (slow)
2014/07/15 10:18:43
Done.
|
| + if (!oobe_complete) { |
| + g_browser_process->platform_part()->session_manager()->SetSessionState( |
| + session_manager::SessionManager::SESSION_STATE_OOBE); |
| + } else { |
| + g_browser_process->platform_part()->session_manager()->SetSessionState( |
| + session_manager::SessionManager::SESSION_STATE_LOGIN_PRIMARY); |
| + } |
| + |
| LoginDisplayHost* display_host = new LoginDisplayHostImpl(screen_bounds); |
| bool show_app_launch_splash_screen = (first_screen_name == |
| @@ -1194,8 +1205,6 @@ void ShowLoginWizard(const std::string& first_screen_name) { |
| return; |
| } |
| - // Check whether we need to execute OOBE process. |
| - bool oobe_complete = chromeos::StartupUtils::IsOobeCompleted(); |
| policy::BrowserPolicyConnectorChromeOS* connector = |
| g_browser_process->platform_part()->browser_policy_connector_chromeos(); |
| bool enrollment_screen_wanted = |