Index: components/autofill/content/common/autofill_messages.h |
diff --git a/components/autofill/content/common/autofill_messages.h b/components/autofill/content/common/autofill_messages.h |
index 078ff83427e4180bbe7fb03dd7fcedfae5f70d44..8aca2622eef17728ef981472e6d026fae065a6af 100644 |
--- a/components/autofill/content/common/autofill_messages.h |
+++ b/components/autofill/content/common/autofill_messages.h |
@@ -102,6 +102,11 @@ IPC_ENUM_TRAITS_MAX_VALUE( |
blink::WebFormElement::AutocompleteResult, |
blink::WebFormElement::AutocompleteResultErrorInvalid) |
+// IPC_MESSAGE macros fail on the std::map, when expanding. We need to define |
+// a type to avoid that. |
+using FormDataFieldDataMap = |
+ std::map<autofill::FormData, autofill::FormFieldData>; |
+ |
// Autofill messages sent from the browser to the renderer. |
// Tells the render frame that a user gesture was observed somewhere in the tab |
@@ -195,6 +200,12 @@ IPC_MESSAGE_ROUTED3(AutofillMsg_RequestAutocompleteResult, |
IPC_MESSAGE_ROUTED1(AutofillMsg_AccountCreationFormsDetected, |
std::vector<autofill::FormData> /* forms */) |
+// Sent when Autofill manager gets the query response from the Autofill server |
+// which contains information about username fields for some forms. |
+// |predictions| maps forms to their username fields. |
+IPC_MESSAGE_ROUTED1(AutofillMsg_AutofillUsernameDataReceived, |
+ FormDataFieldDataMap /* predictions */) |
+ |
// Autofill messages sent from the renderer to the browser. |
// TODO(creis): check in the browser that the renderer actually has permission |