Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1163)

Side by Side Diff: chrome/browser/chromeos/login/ui/login_display_host_impl.cc

Issue 374573006: Force enterprise enrollment flow upon detection of inconsistent state. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/ui/login_display_host_impl.h" 5 #include "chrome/browser/chromeos/login/ui/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 1175 matching lines...) Expand 10 before | Expand all | Expand 10 after
1186 const std::string& auto_launch_app_id = 1186 const std::string& auto_launch_app_id =
1187 chromeos::KioskAppManager::Get()->GetAutoLaunchApp(); 1187 chromeos::KioskAppManager::Get()->GetAutoLaunchApp();
1188 display_host->StartAppLaunch(auto_launch_app_id, 1188 display_host->StartAppLaunch(auto_launch_app_id,
1189 false /* diagnostic_mode */); 1189 false /* diagnostic_mode */);
1190 return; 1190 return;
1191 } 1191 }
1192 1192
1193 policy::BrowserPolicyConnectorChromeOS* connector = 1193 policy::BrowserPolicyConnectorChromeOS* connector =
1194 g_browser_process->platform_part()->browser_policy_connector_chromeos(); 1194 g_browser_process->platform_part()->browser_policy_connector_chromeos();
1195 bool should_show_enrollment_screen = 1195 bool should_show_enrollment_screen =
1196 first_screen_name.empty() && oobe_complete && 1196 chromeos::WizardController::ShouldRecoverEnrollment() ||
1197 chromeos::WizardController::ShouldAutoStartEnrollment() && 1197 ( first_screen_name.empty() && oobe_complete &&
pastarmovj 2014/07/08 12:36:31 nit: no spaces in the braces.
Thiemo Nagel 2014/07/08 14:02:04 Done.
1198 !connector->IsEnterpriseManaged(); 1198 chromeos::WizardController::ShouldAutoStartEnrollment() &&
1199 !connector->IsEnterpriseManaged() );
pastarmovj 2014/07/08 12:36:31 I think you should still respect the first_Screen_
Thiemo Nagel 2014/07/08 14:02:04 Ok, thanks.
1199 if (should_show_enrollment_screen) { 1200 if (should_show_enrollment_screen) {
1200 // Shows networks screen instead of enrollment screen to resume the 1201 // Shows networks screen instead of enrollment screen to resume the
1201 // interrupted auto start enrollment flow because enrollment screen does 1202 // interrupted auto start enrollment flow because enrollment screen does
1202 // not handle flaky network. See http://crbug.com/332572 1203 // not handle flaky network. See http://crbug.com/332572
1203 display_host->StartWizard(chromeos::WizardController::kNetworkScreenName, 1204 display_host->StartWizard(chromeos::WizardController::kNetworkScreenName,
1204 scoped_ptr<base::DictionaryValue>()); 1205 scoped_ptr<base::DictionaryValue>());
1205 return; 1206 return;
1206 } 1207 }
1207 1208
1208 if (StartupUtils::IsEulaAccepted()) { 1209 if (StartupUtils::IsEulaAccepted()) {
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
1261 scoped_ptr<locale_util::SwitchLanguageCallback> callback( 1262 scoped_ptr<locale_util::SwitchLanguageCallback> callback(
1262 new locale_util::SwitchLanguageCallback( 1263 new locale_util::SwitchLanguageCallback(
1263 base::Bind(&OnLanguageSwitchedCallback, base::Passed(data.Pass())))); 1264 base::Bind(&OnLanguageSwitchedCallback, base::Passed(data.Pass()))));
1264 1265
1265 // Load locale keyboards here. Hardware layout would be automatically enabled. 1266 // Load locale keyboards here. Hardware layout would be automatically enabled.
1266 locale_util::SwitchLanguage( 1267 locale_util::SwitchLanguage(
1267 locale, true, true /* login_layouts_only */, callback.Pass()); 1268 locale, true, true /* login_layouts_only */, callback.Pass());
1268 } 1269 }
1269 1270
1270 } // namespace chromeos 1271 } // namespace chromeos
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698