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

Unified Diff: chrome/browser/ui/views/payments/validating_combobox.cc

Issue 2895473005: [Payments] Have expiration date be on the same line in CC editor (Closed)
Patch Set: addressed comments Created 3 years, 7 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 | « chrome/browser/ui/views/payments/validating_combobox.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/views/payments/validating_combobox.cc
diff --git a/chrome/browser/ui/views/payments/validating_combobox.cc b/chrome/browser/ui/views/payments/validating_combobox.cc
index 080bb85876ebc9f631dd40d568cce959a59a1dc8..642cae4b1b499185f405c5dca4ca739250e6f113 100644
--- a/chrome/browser/ui/views/payments/validating_combobox.cc
+++ b/chrome/browser/ui/views/payments/validating_combobox.cc
@@ -23,11 +23,9 @@ ValidatingCombobox::~ValidatingCombobox() {}
void ValidatingCombobox::OnBlur() {
Combobox::OnBlur();
- // The first validation should be on a blur. The subsequent validations will
- // occur when the content changes. Do not validate if the view is being
- // removed.
- if (!was_blurred_ && !being_removed_) {
- was_blurred_ = true;
+ // Validations will occur when the content changes. Do not validate if the
+ // view is being removed.
+ if (!being_removed_) {
Validate();
}
}
@@ -39,11 +37,6 @@ void ValidatingCombobox::ViewHierarchyChanged(
}
void ValidatingCombobox::OnContentsChanged() {
- // Validation on every keystroke only happens if the field has been validated
- // before as part of a blur.
- if (!was_blurred_)
- return;
-
Validate();
}
« no previous file with comments | « chrome/browser/ui/views/payments/validating_combobox.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698