Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2221)

Unified Diff: chrome/browser/ui/autofill/autofill_dialog_controller_impl.h

Issue 12893007: Implementing VERIFY_CVV required action. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 7 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/autofill/autofill_dialog_controller_impl.h
diff --git a/chrome/browser/ui/autofill/autofill_dialog_controller_impl.h b/chrome/browser/ui/autofill/autofill_dialog_controller_impl.h
index 906e0ce198ad7702a5af8cfed8180ae87cbbfdd1..9710f82ad506b740ef631b72f49bf6f880936f3f 100644
--- a/chrome/browser/ui/autofill/autofill_dialog_controller_impl.h
+++ b/chrome/browser/ui/autofill/autofill_dialog_controller_impl.h
@@ -25,7 +25,6 @@
#include "components/autofill/browser/form_structure.h"
#include "components/autofill/browser/personal_data_manager.h"
#include "components/autofill/browser/personal_data_manager_observer.h"
-#include "components/autofill/browser/wallet/required_action.h"
#include "components/autofill/browser/wallet/wallet_client.h"
#include "components/autofill/browser/wallet/wallet_client_delegate.h"
#include "components/autofill/browser/wallet/wallet_signin_helper_delegate.h"
@@ -118,8 +117,8 @@ class AutofillDialogControllerImpl : public AutofillDialogController,
AutofillFieldType type) OVERRIDE;
virtual ui::MenuModel* MenuModelForSection(DialogSection section) OVERRIDE;
virtual string16 LabelForSection(DialogSection section) const OVERRIDE;
- virtual string16 SuggestionTextForSection(DialogSection section) OVERRIDE;
- virtual gfx::Image SuggestionIconForSection(DialogSection section) OVERRIDE;
+ virtual SuggestionState SuggestionStateForSection(
+ DialogSection section) OVERRIDE;
virtual void EditClickedForSection(DialogSection section) OVERRIDE;
virtual void EditCancelledForSection(DialogSection section) OVERRIDE;
virtual gfx::Image IconForField(AutofillFieldType type,
@@ -143,7 +142,7 @@ class AutofillDialogControllerImpl : public AutofillDialogController,
virtual void EndSignInFlow() OVERRIDE;
virtual void LegalDocumentLinkClicked(const ui::Range& range) OVERRIDE;
virtual void OnCancel() OVERRIDE;
- virtual void OnSubmit() OVERRIDE;
+ virtual void OnAccept() OVERRIDE;
virtual Profile* profile() OVERRIDE;
virtual content::WebContents* web_contents() OVERRIDE;
@@ -303,6 +302,19 @@ class AutofillDialogControllerImpl : public AutofillDialogController,
DialogSection SectionForSuggestionsMenuModel(
const SuggestionsMenuModel& model);
+ // Suggested text and icons for sections. Suggestion text is used to show an
+ // abidged overview of the currently used suggestion. Extra text is used when
+ // part of a section is suggested but part must be manually input (e.g. during
+ // a CVC challenge or when using Autofill's CC section [never stores CVC]).
+ string16 SuggestionTextForSection(DialogSection section);
+ string16 RequiredActionTextForSection(DialogSection section) const;
+ gfx::Image SuggestionIconForSection(DialogSection section);
+ string16 ExtraSuggestionTextForSection(DialogSection section) const;
+ gfx::Image ExtraSuggestionIconForSection(DialogSection section) const;
+
+ // Whether |section| should be showing an "Edit" link.
+ bool EditEnabledForSection(DialogSection section) const;
+
// Loads profiles that can suggest data for |type|. |field_contents| is the
// part the user has already typed. |inputs| is the rest of section.
// Identifying info is loaded into the last three outparams as well as
@@ -345,6 +357,9 @@ class AutofillDialogControllerImpl : public AutofillDialogController,
// This information is decoded to reveal a fronting (proxy) card.
void GetFullWallet();
+ // Whether submission is currently waiting for |action| to be handled.
+ bool IsSubmitPausedOn(wallet::RequiredAction action) const;
+
// Called when there's nothing left to accept, update, save, or authenticate
// in order to fill |form_structure_| and pass data back to the invoking page.
void FinishSubmit();
@@ -454,8 +469,9 @@ class AutofillDialogControllerImpl : public AutofillDialogController,
// Whether this is an Autocheckout or a requestAutocomplete dialog.
const DialogType dialog_type_;
- // True if the termination action was a submit.
- bool did_submit_;
+ // True after the user first accepts the dialog and presses "Submit". May
+ // continue to be true while processing required actions.
+ bool is_submitting_;
// Whether or not an Autocheckout flow is running.
bool autocheckout_is_running_;

Powered by Google App Engine
This is Rietveld 408576698