OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 #ifndef COMPONENTS_AUTOFILL_CORE_BROWSER_AUTOFILL_EXPERIMENTS_H_ | 5 #ifndef COMPONENTS_AUTOFILL_CORE_BROWSER_AUTOFILL_EXPERIMENTS_H_ |
6 #define COMPONENTS_AUTOFILL_CORE_BROWSER_AUTOFILL_EXPERIMENTS_H_ | 6 #define COMPONENTS_AUTOFILL_CORE_BROWSER_AUTOFILL_EXPERIMENTS_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/strings/string16.h" | 10 #include "base/strings/string16.h" |
11 #include "base/time/time.h" | 11 #include "base/time/time.h" |
12 #include "third_party/skia/include/core/SkColor.h" | 12 #include "third_party/skia/include/core/SkColor.h" |
13 | 13 |
14 class PrefService; | 14 class PrefService; |
15 | 15 |
16 namespace base { | 16 namespace base { |
17 struct Feature; | 17 struct Feature; |
18 } | 18 } |
19 | 19 |
20 namespace syncer { | 20 namespace syncer { |
21 class SyncService; | 21 class SyncService; |
22 } | 22 } |
23 | 23 |
24 namespace autofill { | 24 namespace autofill { |
25 | 25 |
26 struct Suggestion; | 26 struct Suggestion; |
27 | 27 |
28 extern const base::Feature kAutofillCreditCardAssist; | 28 extern const base::Feature kAutofillCreditCardAssist; |
29 extern const base::Feature kAutofillScanCardholderName; | 29 extern const base::Feature kAutofillScanCardholderName; |
30 extern const base::Feature kAutofillCreditCardBankNameDisplay; | |
31 extern const base::Feature kAutofillCreditCardPopupLayout; | 30 extern const base::Feature kAutofillCreditCardPopupLayout; |
32 extern const base::Feature kAutofillCreditCardLastUsedDateDisplay; | 31 extern const base::Feature kAutofillCreditCardLastUsedDateDisplay; |
33 extern const base::Feature kAutofillOfferLocalSaveIfServerCardManuallyEntered; | 32 extern const base::Feature kAutofillOfferLocalSaveIfServerCardManuallyEntered; |
34 extern const base::Feature kAutofillUpstreamRequestCvcIfMissing; | 33 extern const base::Feature kAutofillUpstreamRequestCvcIfMissing; |
35 extern const base::Feature kAutofillUpstreamUseAutofillProfileComparator; | 34 extern const base::Feature kAutofillUpstreamUseAutofillProfileComparator; |
36 extern const base::Feature kAutofillUpstreamUseNotRecentlyUsedAutofillProfile; | 35 extern const base::Feature kAutofillUpstreamUseNotRecentlyUsedAutofillProfile; |
37 extern const char kCreditCardSigninPromoImpressionLimitParamKey[]; | 36 extern const char kCreditCardSigninPromoImpressionLimitParamKey[]; |
38 extern const char kAutofillCreditCardLastUsedDateShowExpirationDateKey[]; | 37 extern const char kAutofillCreditCardLastUsedDateShowExpirationDateKey[]; |
39 extern const char kAutofillUpstreamMaxMinutesSinceAutofillProfileUseKey[]; | 38 extern const char kAutofillUpstreamMaxMinutesSinceAutofillProfileUseKey[]; |
40 | 39 |
(...skipping 26 matching lines...) Expand all Loading... |
67 // enabled. | 66 // enabled. |
68 bool IsAutofillCreditCardPopupLayoutExperimentEnabled(); | 67 bool IsAutofillCreditCardPopupLayoutExperimentEnabled(); |
69 | 68 |
70 // Returns whether Autofill credit card last used date display experiment is | 69 // Returns whether Autofill credit card last used date display experiment is |
71 // enabled. | 70 // enabled. |
72 bool IsAutofillCreditCardLastUsedDateDisplayExperimentEnabled(); | 71 bool IsAutofillCreditCardLastUsedDateDisplayExperimentEnabled(); |
73 | 72 |
74 // Returns whether Autofill credit card last used date shows expiration date. | 73 // Returns whether Autofill credit card last used date shows expiration date. |
75 bool ShowExpirationDateInAutofillCreditCardLastUsedDate(); | 74 bool ShowExpirationDateInAutofillCreditCardLastUsedDate(); |
76 | 75 |
77 // Returns whether Autofill credit card bank name display experiment is enabled. | |
78 bool IsAutofillCreditCardBankNameDisplayExperimentEnabled(); | |
79 | |
80 // Returns the background color for credit card autofill popup, or | 76 // Returns the background color for credit card autofill popup, or |
81 // |SK_ColorTRANSPARENT| if the new credit card autofill popup layout experiment | 77 // |SK_ColorTRANSPARENT| if the new credit card autofill popup layout experiment |
82 // is not enabled. | 78 // is not enabled. |
83 SkColor GetCreditCardPopupBackgroundColor(); | 79 SkColor GetCreditCardPopupBackgroundColor(); |
84 | 80 |
85 // Returns the divider color for credit card autofill popup, or | 81 // Returns the divider color for credit card autofill popup, or |
86 // |SK_ColorTRANSPARENT| if the new credit card autofill popup layout experiment | 82 // |SK_ColorTRANSPARENT| if the new credit card autofill popup layout experiment |
87 // is not enabled. | 83 // is not enabled. |
88 SkColor GetCreditCardPopupDividerColor(); | 84 SkColor GetCreditCardPopupDividerColor(); |
89 | 85 |
(...skipping 30 matching lines...) Expand all Loading... |
120 bool IsAutofillUpstreamRequestCvcIfMissingExperimentEnabled(); | 116 bool IsAutofillUpstreamRequestCvcIfMissingExperimentEnabled(); |
121 | 117 |
122 // Returns the maximum time that could have elapsed since an address profile's | 118 // Returns the maximum time that could have elapsed since an address profile's |
123 // most recent use for the adress profile to be included in the candidate set | 119 // most recent use for the adress profile to be included in the candidate set |
124 // for card upload. Returns 0 if the experiment is not enabled. | 120 // for card upload. Returns 0 if the experiment is not enabled. |
125 base::TimeDelta GetMaxTimeSinceAutofillProfileUseForCardUpload(); | 121 base::TimeDelta GetMaxTimeSinceAutofillProfileUseForCardUpload(); |
126 | 122 |
127 } // namespace autofill | 123 } // namespace autofill |
128 | 124 |
129 #endif // COMPONENTS_AUTOFILL_CORE_BROWSER_AUTOFILL_EXPERIMENTS_H_ | 125 #endif // COMPONENTS_AUTOFILL_CORE_BROWSER_AUTOFILL_EXPERIMENTS_H_ |
OLD | NEW |