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/ui/webui/chromeos/login/enterprise_oauth_enrollment_scr een_handler.h" | 5 #include "chrome/browser/ui/webui/chromeos/login/enterprise_oauth_enrollment_scr een_handler.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 | 8 |
9 #include "base/bind.h" | 9 #include "base/bind.h" |
10 #include "base/bind_helpers.h" | 10 #include "base/bind_helpers.h" |
(...skipping 213 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
224 NOTREACHED(); | 224 NOTREACHED(); |
225 } | 225 } |
226 | 226 |
227 void EnterpriseOAuthEnrollmentScreenHandler::ShowEnrollmentStatus( | 227 void EnterpriseOAuthEnrollmentScreenHandler::ShowEnrollmentStatus( |
228 policy::EnrollmentStatus status) { | 228 policy::EnrollmentStatus status) { |
229 switch (status.status()) { | 229 switch (status.status()) { |
230 case policy::EnrollmentStatus::STATUS_SUCCESS: | 230 case policy::EnrollmentStatus::STATUS_SUCCESS: |
231 ShowStep(kEnrollmentStepSuccess); | 231 ShowStep(kEnrollmentStepSuccess); |
232 return; | 232 return; |
233 case policy::EnrollmentStatus::STATUS_REGISTRATION_FAILED: | 233 case policy::EnrollmentStatus::STATUS_REGISTRATION_FAILED: |
234 // TODO: have specific messaging for robot auth errors? Seems to low-level | |
235 // for users to do anything about? | |
Mattias Nissler (ping if slow)
2013/03/19 06:33:08
We thought so too in the first iteration of this c
David Roche
2013/04/02 01:59:25
Okay. I didn't want to clutter it up with extra m
Mattias Nissler (ping if slow)
2013/04/02 14:16:46
We'll have to tell chrome-ui-review@ about the str
David Roche
2013/04/04 01:39:53
How should I go about this? Should I start a new
Mattias Nissler (ping if slow)
2013/04/04 13:18:34
In this case (only error messsages) I think it's O
| |
236 case policy::EnrollmentStatus::STATUS_ROBOT_AUTH_FETCH_FAILED: | |
237 case policy::EnrollmentStatus::STATUS_ROBOT_REFRESH_FETCH_FAILED: | |
234 // Some special cases for generating a nicer message that's more helpful. | 238 // Some special cases for generating a nicer message that's more helpful. |
235 switch (status.client_status()) { | 239 switch (status.client_status()) { |
236 case policy::DM_STATUS_SERVICE_MISSING_LICENSES: | 240 case policy::DM_STATUS_SERVICE_MISSING_LICENSES: |
237 ShowError(IDS_ENTERPRISE_ENROLLMENT_MISSING_LICENSES_ERROR, true); | 241 ShowError(IDS_ENTERPRISE_ENROLLMENT_MISSING_LICENSES_ERROR, true); |
238 break; | 242 break; |
239 case policy::DM_STATUS_SERVICE_MANAGEMENT_NOT_SUPPORTED: | 243 case policy::DM_STATUS_SERVICE_MANAGEMENT_NOT_SUPPORTED: |
240 ShowError(IDS_ENTERPRISE_ENROLLMENT_ACCOUNT_ERROR, true); | 244 ShowError(IDS_ENTERPRISE_ENROLLMENT_ACCOUNT_ERROR, true); |
241 break; | 245 break; |
242 default: | 246 default: |
243 ShowErrorMessage( | 247 ShowErrorMessage( |
(...skipping 277 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
521 screen_data.SetBoolean("is_auto_enrollment", is_auto_enrollment_); | 525 screen_data.SetBoolean("is_auto_enrollment", is_auto_enrollment_); |
522 if (!test_email_.empty()) { | 526 if (!test_email_.empty()) { |
523 screen_data.SetString("test_email", test_email_); | 527 screen_data.SetString("test_email", test_email_); |
524 screen_data.SetString("test_password", test_password_); | 528 screen_data.SetString("test_password", test_password_); |
525 } | 529 } |
526 | 530 |
527 ShowScreen(OobeUI::kScreenOobeEnrollment, &screen_data); | 531 ShowScreen(OobeUI::kScreenOobeEnrollment, &screen_data); |
528 } | 532 } |
529 | 533 |
530 } // namespace chromeos | 534 } // namespace chromeos |
OLD | NEW |