| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "components/autofill/content/renderer/autofill_agent.h" | 5 #include "components/autofill/content/renderer/autofill_agent.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include <tuple> | 9 #include <tuple> |
| 10 | 10 |
| (...skipping 263 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 274 GetAutofillDriver()->WillSubmitForm(form_data, base::TimeTicks::Now()); | 274 GetAutofillDriver()->WillSubmitForm(form_data, base::TimeTicks::Now()); |
| 275 submitted_forms_.insert(form_data); | 275 submitted_forms_.insert(form_data); |
| 276 } | 276 } |
| 277 | 277 |
| 278 if (form_submitted) { | 278 if (form_submitted) { |
| 279 GetAutofillDriver()->FormSubmitted(form_data); | 279 GetAutofillDriver()->FormSubmitted(form_data); |
| 280 } | 280 } |
| 281 } | 281 } |
| 282 | 282 |
| 283 void AutofillAgent::Shutdown() { | 283 void AutofillAgent::Shutdown() { |
| 284 binding_.Close(); |
| 284 legacy_.Shutdown(); | 285 legacy_.Shutdown(); |
| 285 weak_ptr_factory_.InvalidateWeakPtrs(); | 286 weak_ptr_factory_.InvalidateWeakPtrs(); |
| 286 } | 287 } |
| 287 | 288 |
| 288 void AutofillAgent::FocusChangeComplete() { | 289 void AutofillAgent::FocusChangeComplete() { |
| 289 WebDocument doc = render_frame()->GetWebFrame()->document(); | 290 WebDocument doc = render_frame()->GetWebFrame()->document(); |
| 290 WebElement focused_element; | 291 WebElement focused_element; |
| 291 if (!doc.isNull()) | 292 if (!doc.isNull()) |
| 292 focused_element = doc.focusedElement(); | 293 focused_element = doc.focusedElement(); |
| 293 if (!focused_element.isNull()) { | 294 if (!focused_element.isNull()) { |
| (...skipping 513 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 807 void AutofillAgent::LegacyAutofillAgent::OnDestruct() { | 808 void AutofillAgent::LegacyAutofillAgent::OnDestruct() { |
| 808 // No-op. Don't delete |this|. | 809 // No-op. Don't delete |this|. |
| 809 } | 810 } |
| 810 | 811 |
| 811 void AutofillAgent::LegacyAutofillAgent::FocusChangeComplete() { | 812 void AutofillAgent::LegacyAutofillAgent::FocusChangeComplete() { |
| 812 if (agent_) | 813 if (agent_) |
| 813 agent_->FocusChangeComplete(); | 814 agent_->FocusChangeComplete(); |
| 814 } | 815 } |
| 815 | 816 |
| 816 } // namespace autofill | 817 } // namespace autofill |
| OLD | NEW |