| Index: components/autofill/content/renderer/autofill_agent.cc
|
| diff --git a/components/autofill/content/renderer/autofill_agent.cc b/components/autofill/content/renderer/autofill_agent.cc
|
| index a287c5b45270323e479fe6957215b14d7df04a02..f1835d73cb94d9529610f896e277710fe2b6ca5a 100644
|
| --- a/components/autofill/content/renderer/autofill_agent.cc
|
| +++ b/components/autofill/content/renderer/autofill_agent.cc
|
| @@ -762,20 +762,16 @@ bool AutofillAgent::IsUserGesture() const {
|
| return WebUserGestureIndicator::isProcessingUserGesture();
|
| }
|
|
|
| -void AutofillAgent::didAssociateFormControls(const WebVector<WebNode>& nodes) {
|
| - for (size_t i = 0; i < nodes.size(); ++i) {
|
| - WebLocalFrame* frame = nodes[i].document().frame();
|
| - // Only monitors dynamic forms created in the top frame. Dynamic forms
|
| - // inserted in iframes are not captured yet. Frame is only processed
|
| - // if it has finished loading, otherwise you can end up with a partially
|
| - // parsed form.
|
| - if (frame && !frame->isLoading()) {
|
| - ProcessForms();
|
| - password_autofill_agent_->OnDynamicFormsSeen();
|
| - if (password_generation_agent_)
|
| - password_generation_agent_->OnDynamicFormsSeen();
|
| - return;
|
| - }
|
| +void AutofillAgent::didAssociateFormControlsDynamically() {
|
| + blink::WebLocalFrame* frame = render_frame()->GetWebFrame();
|
| +
|
| + // Frame is only processed if it has finished loading, otherwise you can end
|
| + // up with a partially parsed form.
|
| + if (frame && !frame->isLoading()) {
|
| + ProcessForms();
|
| + password_autofill_agent_->OnDynamicFormsSeen();
|
| + if (password_generation_agent_)
|
| + password_generation_agent_->OnDynamicFormsSeen();
|
| }
|
| }
|
|
|
|
|