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

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

Issue 2874933008: Adds animation as feature variation to keyboard accessory. (Closed)
Patch Set: Merge forward Created 3 years, 7 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/autofill_external_delegate.cc
diff --git a/components/autofill/core/browser/autofill_external_delegate.cc b/components/autofill/core/browser/autofill_external_delegate.cc
index 3db7f0fd00bead2a98bb3d080139eddd21755973..aedfc7c41b97fae10ca5524a926a0c8dc583e30f 100644
--- a/components/autofill/core/browser/autofill_external_delegate.cc
+++ b/components/autofill/core/browser/autofill_external_delegate.cc
@@ -83,9 +83,18 @@ void AutofillExternalDelegate::OnSuggestionsReturned(
if (query_id != query_id_)
return;
+ std::vector<Suggestion> suggestions;
+
+ if (IsHintBeforeKeyboardAccessorySuggestions()) {
please use gerrit instead 2017/05/15 14:37:29 #if defined(OS_ANDROID)
csashi 2017/05/15 20:07:26 Done.
+ Suggestion create_icon;
+ create_icon.icon = base::ASCIIToUTF16("create");
+ suggestions.push_back(create_icon);
+ }
+
// The suggestions and warnings are "above the fold" and are separated from
// other menu items with a separator.
- std::vector<Suggestion> suggestions(input_suggestions);
+ suggestions.insert(suggestions.end(), input_suggestions.begin(),
+ input_suggestions.end());
// Hide warnings as appropriate.
PossiblyRemoveAutofillWarnings(&suggestions);

Powered by Google App Engine
This is Rietveld 408576698