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

Unified Diff: chrome/browser/ui/passwords/manage_passwords_ui_controller.cc

Issue 861103002: Credentials chooser UI for Android. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Review, please Created 5 years, 10 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/passwords/manage_passwords_ui_controller.cc
diff --git a/chrome/browser/ui/passwords/manage_passwords_ui_controller.cc b/chrome/browser/ui/passwords/manage_passwords_ui_controller.cc
index 47e20045506d50e4ae951df35774a76a90a06ff9..72625212358e9912cc66fc40adfdde7e0bffcc83 100644
--- a/chrome/browser/ui/passwords/manage_passwords_ui_controller.cc
+++ b/chrome/browser/ui/passwords/manage_passwords_ui_controller.cc
@@ -24,6 +24,8 @@
#if defined(OS_ANDROID)
#include "chrome/browser/android/chromium_application.h"
+#include "chrome/browser/infobars/infobar_service.h"
+#include "chrome/browser/password_manager/account_chooser_infobar_delegate_android.h"
#endif
using autofill::PasswordFormMap;
@@ -128,7 +130,14 @@ bool ManagePasswordsUIController::OnChooseCredentials(
// The map is useless because usernames may overlap.
password_form_map_.clear();
SetState(password_manager::ui::CREDENTIAL_REQUEST_AND_BUBBLE_STATE);
+#if defined(OS_ANDROID)
+ AccountChooserInfoBarDelegateAndroid::Create(
+ InfoBarService::FromWebContents(web_contents()), this);
+ credentials_callback_ = callback;
+ return true;
Peter Kasting 2015/02/18 00:23:05 If you're going to return true here, you need to p
melandory 2015/02/18 21:15:34 Done.
+#else
UpdateBubbleAndIconVisibility();
+#endif
if (bubble_shown_)
credentials_callback_ = callback;
return bubble_shown_;

Powered by Google App Engine
This is Rietveld 408576698