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

Unified Diff: chrome/browser/autofill/autofill_manager.cc

Issue 7602006: Add preliminary Autofill support for the 'autocompletetype' attribute. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Prevent DOS Created 9 years, 4 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
« no previous file with comments | « no previous file | chrome/browser/autofill/form_structure.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/autofill/autofill_manager.cc
diff --git a/chrome/browser/autofill/autofill_manager.cc b/chrome/browser/autofill/autofill_manager.cc
index ce5913331676805783ba60114186200c591a8868..d8c025b4f442595dc76c786c5bc01d825a616a95 100644
--- a/chrome/browser/autofill/autofill_manager.cc
+++ b/chrome/browser/autofill/autofill_manager.cc
@@ -423,8 +423,10 @@ void AutofillManager::OnFormSubmitted(const FormData& form) {
if (!personal_data_->profiles().empty() ||
!personal_data_->credit_cards().empty()) {
DeterminePossibleFieldTypesForUpload(&submitted_form);
- UploadFormData(submitted_form);
submitted_form.LogQualityMetrics(*metric_logger_);
+
+ if (submitted_form.ShouldBeCrowdsourced())
+ UploadFormData(submitted_form);
}
if (!submitted_form.IsAutofillable(true))
@@ -1097,9 +1099,9 @@ void AutofillManager::ParseForms(const std::vector<FormData>& forms) {
form_structure->DetermineHeuristicTypes();
- // Set aside forms with method GET so that they are not included in the
- // query to the server.
- if (form_structure->ShouldBeParsed(true))
+ // Set aside forms with method GET or author-specified types, so that they
+ // are not included in the query to the server.
+ if (form_structure->ShouldBeCrowdsourced())
form_structures_.push_back(form_structure.release());
else
non_queryable_forms.push_back(form_structure.release());
« no previous file with comments | « no previous file | chrome/browser/autofill/form_structure.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698