| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/signin/user_manager_screen_handler.h" | 5 #include "chrome/browser/ui/webui/signin/user_manager_screen_handler.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 #include <utility> | 8 #include <utility> |
| 9 | 9 |
| 10 #include "base/bind.h" | 10 #include "base/bind.h" |
| (...skipping 651 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 662 IDS_LOGIN_POD_USER_REMOVE_WARNING_SYNC) : | 662 IDS_LOGIN_POD_USER_REMOVE_WARNING_SYNC) : |
| 663 (has_errors ? IDS_LOGIN_POD_USER_REMOVE_WARNING_NONSYNC_WITH_ERRORS : | 663 (has_errors ? IDS_LOGIN_POD_USER_REMOVE_WARNING_NONSYNC_WITH_ERRORS : |
| 664 IDS_LOGIN_POD_USER_REMOVE_WARNING_NONSYNC); | 664 IDS_LOGIN_POD_USER_REMOVE_WARNING_NONSYNC); |
| 665 | 665 |
| 666 base::StringValue message = base::StringValue( | 666 base::StringValue message = base::StringValue( |
| 667 l10n_util::GetPluralStringFUTF16(message_id, total_count)); | 667 l10n_util::GetPluralStringFUTF16(message_id, total_count)); |
| 668 | 668 |
| 669 web_ui()->CallJavascriptFunction("updateRemoveWarningDialogSetMessage", | 669 web_ui()->CallJavascriptFunction("updateRemoveWarningDialogSetMessage", |
| 670 base::StringValue(profile_path), | 670 base::StringValue(profile_path), |
| 671 message, | 671 message, |
| 672 base::FundamentalValue(is_synced_user), |
| 672 base::FundamentalValue(total_count)); | 673 base::FundamentalValue(total_count)); |
| 673 } | 674 } |
| 674 | 675 |
| 675 void UserManagerScreenHandler::OnGetTokenInfoResponse( | 676 void UserManagerScreenHandler::OnGetTokenInfoResponse( |
| 676 scoped_ptr<base::DictionaryValue> token_info) { | 677 scoped_ptr<base::DictionaryValue> token_info) { |
| 677 // Password is unchanged so user just mistyped it. Ask again. | 678 // Password is unchanged so user just mistyped it. Ask again. |
| 678 ReportAuthenticationResult(false, ProfileMetrics::AUTH_FAILED); | 679 ReportAuthenticationResult(false, ProfileMetrics::AUTH_FAILED); |
| 679 } | 680 } |
| 680 | 681 |
| 681 void UserManagerScreenHandler::OnOAuthError() { | 682 void UserManagerScreenHandler::OnOAuthError() { |
| (...skipping 334 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1016 Profile* profile, Profile::CreateStatus profile_create_status) { | 1017 Profile* profile, Profile::CreateStatus profile_create_status) { |
| 1017 Browser* browser = chrome::FindAnyBrowser(profile, false, desktop_type_); | 1018 Browser* browser = chrome::FindAnyBrowser(profile, false, desktop_type_); |
| 1018 if (browser && browser->window()) { | 1019 if (browser && browser->window()) { |
| 1019 OnBrowserWindowReady(browser); | 1020 OnBrowserWindowReady(browser); |
| 1020 } else { | 1021 } else { |
| 1021 registrar_.Add(this, | 1022 registrar_.Add(this, |
| 1022 chrome::NOTIFICATION_BROWSER_WINDOW_READY, | 1023 chrome::NOTIFICATION_BROWSER_WINDOW_READY, |
| 1023 content::NotificationService::AllSources()); | 1024 content::NotificationService::AllSources()); |
| 1024 } | 1025 } |
| 1025 } | 1026 } |
| OLD | NEW |