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

Unified Diff: components/password_manager/core/browser/password_manager.cc

Issue 1402803002: [Password Manager] Pass origin of the form which was autofilled in order to display it in managemen… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 2 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: components/password_manager/core/browser/password_manager.cc
diff --git a/components/password_manager/core/browser/password_manager.cc b/components/password_manager/core/browser/password_manager.cc
index d55849868e5d709f64fa1ef477a50333bf2f691e..b609e6fb3aeedd789fae1cea0e1b0f7955cd9c95 100644
--- a/components/password_manager/core/browser/password_manager.cc
+++ b/components/password_manager/core/browser/password_manager.cc
@@ -740,7 +740,7 @@ void PasswordManager::Autofill(password_manager::PasswordManagerDriver* driver,
PreferredRealmIsFromAndroid(fill_data));
driver->FillPasswordForm(fill_data);
- client_->PasswordWasAutofilled(best_matches);
+ client_->PasswordWasAutofilled(best_matches, form_for_autofill.origin);
}
void PasswordManager::AutofillHttpAuth(
@@ -758,8 +758,9 @@ void PasswordManager::AutofillHttpAuth(
FOR_EACH_OBSERVER(LoginModelObserver, observers_,
OnAutofillDataAvailable(preferred_match));
-
- client_->PasswordWasAutofilled(best_matches);
+ DCHECK(!best_matches.empty());
+ client_->PasswordWasAutofilled(best_matches,
+ best_matches.begin()->second->origin);
}
void PasswordManager::ProcessAutofillPredictions(

Powered by Google App Engine
This is Rietveld 408576698