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

Side by Side Diff: chrome/browser/autofill/wallet/required_action.h

Issue 11777007: Adds wallet::RequiredAction for when we start interacting with Online Wallet. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: isherman@ review Created 7 years, 11 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef CHROME_BROWSER_AUTOFILL_WALLET_REQUIRED_ACTION_H_
6 #define CHROME_BROWSER_AUTOFILL_WALLET_REQUIRED_ACTION_H_
7
8 #include <string>
9
10 namespace wallet {
11
12 // Matches a subset of wallet proto values for required actions. Missing values
13 // are either deprecated or don't apply to Chrome's use of Online Wallet.
14 enum RequiredAction {
15 UNKNOWN_TYPE = 0, // Catch all type, not in proto.
16 SETUP_WALLET = 1,
17 ACCEPT_TOS = 2,
18 GAIA_AUTH = 4,
19 UPDATE_EXPIRATION_DATE = 7,
20 UPGRADE_MIN_ADDRESS = 8,
21 INVALID_FORM_FIELD = 11,
22 CVC_RISK_CHALLENGE = 12,
ahutter 2013/01/07 17:50:11 Since we're only getting the string representation
Dan Beam 2013/01/07 18:29:08 Done.
23 };
24
25 // Static helper functions to determine if an RequiredAction applies to either a
26 // FullWallet or WalletItems.
27 bool ActionAppliesToFullWallet(RequiredAction action);
28 bool ActionAppliesToWalletItems(RequiredAction action);
29
30 // Turn a string value of the parsed JSON response into an RequiredAction.
31 RequiredAction ParseRequiredActionFromString(const std::string& str);
32
33 } // namespace wallet
34
35 #endif // CHROME_BROWSER_AUTOFILL_WALLET_REQUIRED_ACTION_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698