| 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 5b94eaebd58813de8e77b2f32fda1ef76d655216..775e0e13577938b5b8131173c5444048fb0ccb7e 100644
|
| --- a/components/autofill/content/renderer/autofill_agent.cc
|
| +++ b/components/autofill/content/renderer/autofill_agent.cc
|
| @@ -394,10 +394,14 @@ void AutofillAgent::textFieldDidEndEditing(const WebInputElement& element) {
|
|
|
| void AutofillAgent::textFieldDidChange(const WebFormControlElement& element) {
|
| DCHECK(toWebInputElement(&element) || form_util::IsTextAreaElement(element));
|
| +
|
| if (ignore_text_changes_)
|
| return;
|
|
|
| - if (!IsUserGesture())
|
| + // Disregard text changes that aren't caused by user gestures or pastes. Note
|
| + // that pastes aren't necessarily user gestures because Blink's conception of
|
| + // user gestures is centered around creating new windows/tabs.
|
| + if (!IsUserGesture() && !render_frame()->IsPasting())
|
| return;
|
|
|
| // We post a task for doing the Autofill as the caret position is not set
|
|
|