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

Unified Diff: components/autofill/core/browser/autocomplete_history_manager.cc

Issue 204343004: Add supports that allow Autofill to be initiated from textarea field (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Correct the returned value expectations for OnSuggestionReturned() Created 6 years, 9 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/autofill/core/browser/autocomplete_history_manager.cc
diff --git a/components/autofill/core/browser/autocomplete_history_manager.cc b/components/autofill/core/browser/autocomplete_history_manager.cc
index 6562157e946e7a302901ff269092eb20f4635e34..d4737632ad3f9767665ad00ff4f1d0ae31fb55e1 100644
--- a/components/autofill/core/browser/autocomplete_history_manager.cc
+++ b/components/autofill/core/browser/autocomplete_history_manager.cc
@@ -81,6 +81,7 @@ void AutocompleteHistoryManager::OnGetAutocompleteSuggestions(
int query_id,
const base::string16& name,
const base::string16& prefix,
+ const std::string form_control_type,
const std::vector<base::string16>& autofill_values,
const std::vector<base::string16>& autofill_labels,
const std::vector<base::string16>& autofill_icons,
@@ -92,7 +93,8 @@ void AutocompleteHistoryManager::OnGetAutocompleteSuggestions(
autofill_labels_ = autofill_labels;
autofill_icons_ = autofill_icons;
autofill_unique_ids_ = autofill_unique_ids;
- if (!manager_delegate_->IsAutocompleteEnabled()) {
+ if (!manager_delegate_->IsAutocompleteEnabled() ||
+ form_control_type == "textarea") {
SendSuggestions(NULL);
return;
}

Powered by Google App Engine
This is Rietveld 408576698