Pop up requestAutocomplete UI when autofill server hints chrome client that it is in a multipage autofill flow.
* Added AutofillFlowInfobarDelegate for the Infobar. (Note that this might evolve soon when we have much concrete UX)
* Strings used are also temporary.
* browser/autofill/autofill_flow_util.* : helper functions to build FormStructure representing all the information needed for autofill_flow.
* browser/autofill/autofill_manager.* : Added new methods to pop the UI and callback method to handle data from UI.
* browser/autofill/autofill_xml_parser/form_structure: To get information about step in the autofill flow from autofill servers.
* renderer/autofill/autofill_agent.* : To send SSL Status of the page back to the browser process.
BUG=159830
Review URL: https://chromiumcodereview.appspot.com/11539003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@177746 0039d316-1c4b-4281-b951-d872f2087c98
diff --git a/chrome/browser/autofill/autofill_xml_parser.cc b/chrome/browser/autofill/autofill_xml_parser.cc
index 92a1ede9..425185b7 100644
--- a/chrome/browser/autofill/autofill_xml_parser.cc
+++ b/chrome/browser/autofill/autofill_xml_parser.cc
@@ -33,6 +33,8 @@
std::string* experiment_id)
: field_types_(field_types),
upload_required_(upload_required),
+ current_page_number_(-1),
+ total_pages_(-1),
experiment_id_(experiment_id) {
DCHECK(upload_required_);
DCHECK(experiment_id_);
@@ -89,6 +91,18 @@
// Record this field type.
field_types_->push_back(field_type);
+ } else if (element.compare("autofill_flow") == 0) {
+ // |attrs| is a NULL-terminated list of (attribute, value) pairs.
+ while (*attrs) {
+ buzz::QName attribute_qname = context->ResolveQName(*attrs, true);
+ ++attrs;
+ const std::string& attribute_name = attribute_qname.LocalPart();
+ if (attribute_name.compare("page_no") == 0)
+ current_page_number_ = GetIntValue(context, *attrs);
+ else if (attribute_name.compare("total_pages") == 0)
+ total_pages_ = GetIntValue(context, *attrs);
+ ++attrs;
+ }
}
}