| 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_external_delegate.h" | 5 #include "components/autofill/core/browser/autofill_external_delegate.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| (...skipping 267 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 278 } | 278 } |
| 279 | 279 |
| 280 void AutofillExternalDelegate::ClearPreviewedForm() { | 280 void AutofillExternalDelegate::ClearPreviewedForm() { |
| 281 driver_->RendererShouldClearPreviewedForm(); | 281 driver_->RendererShouldClearPreviewedForm(); |
| 282 } | 282 } |
| 283 | 283 |
| 284 bool AutofillExternalDelegate::IsCreditCardPopup() { | 284 bool AutofillExternalDelegate::IsCreditCardPopup() { |
| 285 return is_credit_card_popup_; | 285 return is_credit_card_popup_; |
| 286 } | 286 } |
| 287 | 287 |
| 288 AutofillDriver* AutofillExternalDelegate::GetAutofillDriver() { |
| 289 return driver_; |
| 290 } |
| 291 |
| 288 void AutofillExternalDelegate::Reset() { | 292 void AutofillExternalDelegate::Reset() { |
| 289 manager_->client()->HideAutofillPopup(); | 293 manager_->client()->HideAutofillPopup(); |
| 290 } | 294 } |
| 291 | 295 |
| 292 base::WeakPtr<AutofillExternalDelegate> AutofillExternalDelegate::GetWeakPtr() { | 296 base::WeakPtr<AutofillExternalDelegate> AutofillExternalDelegate::GetWeakPtr() { |
| 293 return weak_ptr_factory_.GetWeakPtr(); | 297 return weak_ptr_factory_.GetWeakPtr(); |
| 294 } | 298 } |
| 295 | 299 |
| 296 void AutofillExternalDelegate::OnCreditCardScanned(const CreditCard& card) { | 300 void AutofillExternalDelegate::OnCreditCardScanned(const CreditCard& card) { |
| 297 manager_->FillCreditCardForm(query_id_, query_form_, query_field_, card, | 301 manager_->FillCreditCardForm(query_id_, query_form_, query_field_, card, |
| (...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 391 const { | 395 const { |
| 392 if (IsKeyboardAccessoryEnabled()) { | 396 if (IsKeyboardAccessoryEnabled()) { |
| 393 return l10n_util::GetStringUTF16(IDS_AUTOFILL_OPTIONS_CONTENT_DESCRIPTION); | 397 return l10n_util::GetStringUTF16(IDS_AUTOFILL_OPTIONS_CONTENT_DESCRIPTION); |
| 394 } | 398 } |
| 395 return l10n_util::GetStringUTF16(is_credit_card_popup_ ? | 399 return l10n_util::GetStringUTF16(is_credit_card_popup_ ? |
| 396 IDS_AUTOFILL_CREDIT_CARD_OPTIONS_POPUP : | 400 IDS_AUTOFILL_CREDIT_CARD_OPTIONS_POPUP : |
| 397 IDS_AUTOFILL_OPTIONS_POPUP); | 401 IDS_AUTOFILL_OPTIONS_POPUP); |
| 398 } | 402 } |
| 399 | 403 |
| 400 } // namespace autofill | 404 } // namespace autofill |
| OLD | NEW |