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/wizard_controller.h" | 5 #include "chrome/browser/chromeos/login/wizard_controller.h" |
6 | 6 |
7 #include <signal.h> | 7 #include <signal.h> |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 #include <stdlib.h> | 9 #include <stdlib.h> |
10 #include <sys/types.h> | 10 #include <sys/types.h> |
(...skipping 714 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
725 return; | 725 return; |
726 #if defined(GOOGLE_CHROME_BUILD) | 726 #if defined(GOOGLE_CHROME_BUILD) |
727 if (!content::BrowserThread::PostBlockingPoolTask( | 727 if (!content::BrowserThread::PostBlockingPoolTask( |
728 FROM_HERE, base::Bind(&InitializeCrashReporter))) { | 728 FROM_HERE, base::Bind(&InitializeCrashReporter))) { |
729 LOG(ERROR) << "Failed to start crash reporter initialization."; | 729 LOG(ERROR) << "Failed to start crash reporter initialization."; |
730 } | 730 } |
731 #endif | 731 #endif |
732 } | 732 } |
733 | 733 |
734 void WizardController::OnUpdateErrorCheckingForUpdate() { | 734 void WizardController::OnUpdateErrorCheckingForUpdate() { |
735 const bool is_hands_off_mode = | 735 // TODO(nkostylev): Update should be required during OOBE. |
736 (policy::DeviceCloudPolicyManagerChromeOS::GetZeroTouchEnrollmentMode() == | 736 // We do not want to block users from being able to proceed to the login |
737 policy::ZeroTouchEnrollmentMode::HANDS_OFF); | 737 // screen if there is any error checking for an update. |
738 | 738 // They could use "browse without sign-in" feature to set up the network to be |
739 // If there was an error while checking for update, return to the network | 739 // able to perform the update later. |
740 // selection screen if the OOBE isn't complete (unless it's in the zero-touch | 740 OnUpdateCompleted(); |
741 // enrollment mode) as we don't want to miss any critical update. Otherwise, | |
742 // we do not want to block users from being able to proceed to the login | |
743 // screen if there is any error checking for an update. They could use | |
744 // "browse without sign-in" feature to set up the network to be able to | |
745 // perform the update later. | |
746 if (is_out_of_box_ && !is_hands_off_mode) | |
747 ShowNetworkScreen(); | |
748 else | |
749 OnUpdateCompleted(); | |
750 } | 741 } |
751 | 742 |
752 void WizardController::OnUpdateErrorUpdating(bool is_critical_update) { | 743 void WizardController::OnUpdateErrorUpdating(bool is_critical_update) { |
753 // If there was an error while getting or applying the update, return to | 744 // If there was an error while getting or applying the update, return to |
754 // network selection screen if the OOBE isn't complete and the update is | 745 // network selection screen if the OOBE isn't complete and the update is |
755 // deemed critical. Otherwise, similar to OnUpdateErrorCheckingForUpdate(), | 746 // deemed critical. Otherwise, similar to OnUpdateErrorCheckingForUpdate(), |
756 // we do not want to block users from being able to proceed to the login | 747 // we do not want to block users from being able to proceed to the login |
757 // screen. | 748 // screen. |
758 if (is_out_of_box_ && is_critical_update) | 749 if (is_out_of_box_ && is_critical_update) |
759 ShowNetworkScreen(); | 750 ShowNetworkScreen(); |
(...skipping 756 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1516 : policy::EnrollmentConfig::MODE_MANUAL_REENROLLMENT; | 1507 : policy::EnrollmentConfig::MODE_MANUAL_REENROLLMENT; |
1517 } | 1508 } |
1518 | 1509 |
1519 EnrollmentScreen* screen = EnrollmentScreen::Get(this); | 1510 EnrollmentScreen* screen = EnrollmentScreen::Get(this); |
1520 screen->SetParameters(effective_config, shark_controller_.get()); | 1511 screen->SetParameters(effective_config, shark_controller_.get()); |
1521 SetStatusAreaVisible(true); | 1512 SetStatusAreaVisible(true); |
1522 SetCurrentScreen(screen); | 1513 SetCurrentScreen(screen); |
1523 } | 1514 } |
1524 | 1515 |
1525 } // namespace chromeos | 1516 } // namespace chromeos |
OLD | NEW |