| 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 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <algorithm> | 10 #include <algorithm> |
| (...skipping 847 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 858 if (is_new_popup) { | 858 if (is_new_popup) { |
| 859 AutofillMetrics::LogUserHappinessMetric(AutofillMetrics::SUGGESTIONS_SHOWN); | 859 AutofillMetrics::LogUserHappinessMetric(AutofillMetrics::SUGGESTIONS_SHOWN); |
| 860 | 860 |
| 861 if (!did_show_suggestions_) { | 861 if (!did_show_suggestions_) { |
| 862 did_show_suggestions_ = true; | 862 did_show_suggestions_ = true; |
| 863 AutofillMetrics::LogUserHappinessMetric( | 863 AutofillMetrics::LogUserHappinessMetric( |
| 864 AutofillMetrics::SUGGESTIONS_SHOWN_ONCE); | 864 AutofillMetrics::SUGGESTIONS_SHOWN_ONCE); |
| 865 } | 865 } |
| 866 | 866 |
| 867 if (autofill_field->Type().group() == CREDIT_CARD) { | 867 if (autofill_field->Type().group() == CREDIT_CARD) { |
| 868 credit_card_form_event_logger_->OnDidShowSuggestions(); | 868 credit_card_form_event_logger_->OnDidShowSuggestions(*autofill_field); |
| 869 } else { | 869 } else { |
| 870 address_form_event_logger_->OnDidShowSuggestions(); | 870 address_form_event_logger_->OnDidShowSuggestions(*autofill_field); |
| 871 } | 871 } |
| 872 } | 872 } |
| 873 } | 873 } |
| 874 | 874 |
| 875 void AutofillManager::OnHidePopup() { | 875 void AutofillManager::OnHidePopup() { |
| 876 if (!IsAutofillEnabled()) | 876 if (!IsAutofillEnabled()) |
| 877 return; | 877 return; |
| 878 | 878 |
| 879 autocomplete_history_manager_->CancelPendingQuery(); | 879 autocomplete_history_manager_->CancelPendingQuery(); |
| 880 client_->HideAutofillPopup(); | 880 client_->HideAutofillPopup(); |
| (...skipping 1466 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2347 #endif // ENABLE_FORM_DEBUG_DUMP | 2347 #endif // ENABLE_FORM_DEBUG_DUMP |
| 2348 | 2348 |
| 2349 void AutofillManager::LogCardUploadDecisions(int upload_decision_metrics) { | 2349 void AutofillManager::LogCardUploadDecisions(int upload_decision_metrics) { |
| 2350 AutofillMetrics::LogCardUploadDecisionMetrics(upload_decision_metrics); | 2350 AutofillMetrics::LogCardUploadDecisionMetrics(upload_decision_metrics); |
| 2351 AutofillMetrics::LogCardUploadDecisionsUkm(client_->GetUkmRecorder(), | 2351 AutofillMetrics::LogCardUploadDecisionsUkm(client_->GetUkmRecorder(), |
| 2352 pending_upload_request_url_, | 2352 pending_upload_request_url_, |
| 2353 upload_decision_metrics); | 2353 upload_decision_metrics); |
| 2354 } | 2354 } |
| 2355 | 2355 |
| 2356 } // namespace autofill | 2356 } // namespace autofill |
| OLD | NEW |