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

Unified Diff: components/autofill/core/browser/ui/card_unmask_prompt_controller_impl.cc

Issue 2254353002: Prompt for CVC in credit card assist. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Better callback names Created 4 years, 4 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
« no previous file with comments | « components/autofill/core/browser/payments/full_card_request_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/autofill/core/browser/ui/card_unmask_prompt_controller_impl.cc
diff --git a/components/autofill/core/browser/ui/card_unmask_prompt_controller_impl.cc b/components/autofill/core/browser/ui/card_unmask_prompt_controller_impl.cc
index 738b5acbd8cddd38155559ec2fd4682a74bff17d..a922b5a2c750ace7090a7dba9699034d8e959e62 100644
--- a/components/autofill/core/browser/ui/card_unmask_prompt_controller_impl.cc
+++ b/components/autofill/core/browser/ui/card_unmask_prompt_controller_impl.cc
@@ -269,6 +269,8 @@ bool CardUnmaskPromptControllerImpl::CanStoreLocally() const {
return false;
if (reason_ == AutofillClient::UNMASK_FOR_PAYMENT_REQUEST)
return false;
+ if (card_.record_type() == CreditCard::LOCAL_CARD)
+ return false;
return OfferStoreUnmaskedCards();
}
@@ -323,7 +325,9 @@ bool CardUnmaskPromptControllerImpl::InputExpirationIsValid(
base::TimeDelta CardUnmaskPromptControllerImpl::GetSuccessMessageDuration()
const {
return base::TimeDelta::FromMilliseconds(
- reason_ == AutofillClient::UNMASK_FOR_PAYMENT_REQUEST ? 0 : 500);
+ card_.record_type() == CreditCard::LOCAL_CARD ||
+ reason_ == AutofillClient::UNMASK_FOR_PAYMENT_REQUEST
+ ? 0 : 500);
}
} // namespace autofill
« no previous file with comments | « components/autofill/core/browser/payments/full_card_request_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698