| 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/core/browser/autofill_manager.h" | 5 #include "components/autofill/core/browser/autofill_manager.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include <limits> | 9 #include <limits> |
| 10 #include <map> | 10 #include <map> |
| (...skipping 675 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 686 metric_logger_->LogUserHappinessMetric( | 686 metric_logger_->LogUserHappinessMetric( |
| 687 AutofillMetrics::SUGGESTIONS_SHOWN_ONCE); | 687 AutofillMetrics::SUGGESTIONS_SHOWN_ONCE); |
| 688 } | 688 } |
| 689 } | 689 } |
| 690 } | 690 } |
| 691 | 691 |
| 692 void AutofillManager::OnHidePopup() { | 692 void AutofillManager::OnHidePopup() { |
| 693 if (!IsAutofillEnabled()) | 693 if (!IsAutofillEnabled()) |
| 694 return; | 694 return; |
| 695 | 695 |
| 696 autocomplete_history_manager_->CancelPendingQuery(); |
| 696 client_->HideAutofillPopup(); | 697 client_->HideAutofillPopup(); |
| 697 } | 698 } |
| 698 | 699 |
| 699 void AutofillManager::RemoveAutofillProfileOrCreditCard(int unique_id) { | 700 void AutofillManager::RemoveAutofillProfileOrCreditCard(int unique_id) { |
| 700 const AutofillDataModel* data_model = NULL; | 701 const AutofillDataModel* data_model = NULL; |
| 701 size_t variant = 0; | 702 size_t variant = 0; |
| 702 bool unused_is_credit_card = false; | 703 bool unused_is_credit_card = false; |
| 703 if (!GetProfileOrCreditCard( | 704 if (!GetProfileOrCreditCard( |
| 704 unique_id, &data_model, &variant, &unused_is_credit_card)) { | 705 unique_id, &data_model, &variant, &unused_is_credit_card)) { |
| 705 NOTREACHED(); | 706 NOTREACHED(); |
| (...skipping 514 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1220 return false; | 1221 return false; |
| 1221 | 1222 |
| 1222 // Disregard forms that we wouldn't ever autofill in the first place. | 1223 // Disregard forms that we wouldn't ever autofill in the first place. |
| 1223 if (!form.ShouldBeParsed()) | 1224 if (!form.ShouldBeParsed()) |
| 1224 return false; | 1225 return false; |
| 1225 | 1226 |
| 1226 return true; | 1227 return true; |
| 1227 } | 1228 } |
| 1228 | 1229 |
| 1229 } // namespace autofill | 1230 } // namespace autofill |
| OLD | NEW |