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

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

Issue 2055633003: [Password Generation] Sends form classifier vote to autofill server (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@pg_form_classification
Patch Set: Changed enum values Created 4 years, 6 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 766212c8e2b760ae98fe579456e90834bc4fb216..6d008a71cf1ed5acd4c59aa589afd2b3233dcca8 100644
--- a/components/password_manager/core/browser/password_manager.cc
+++ b/components/password_manager/core/browser/password_manager.cc
@@ -231,6 +231,15 @@ void PasswordManager::SetGenerationElementAndReasonForForm(
manager->FetchDataFromPasswordStore();
}
+void PasswordManager::SaveFormClassifierVote(
+ const autofill::PasswordForm& form,
+ const base::string16& generation_field) {
+ DCHECK(client_->IsSavingAndFillingEnabledForCurrentPage());
+ PasswordFormManager* form_manager = GetMatchingPendingManager(form);
+ if (form_manager)
+ form_manager->SaveFormClassifierVote(generation_field);
+}
+
void PasswordManager::ProvisionallySavePassword(const PasswordForm& form) {
bool is_saving_and_filling_enabled =
client_->IsSavingAndFillingEnabledForCurrentPage();

Powered by Google App Engine
This is Rietveld 408576698