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

Unified Diff: chrome/browser/ui/android/autofill/autofill_dialog_view_android.cc

Issue 13607006: rAc: don't clobber user input when accepting autofill popup suggestion (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: merge Created 7 years, 8 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/android/autofill/autofill_dialog_view_android.cc
diff --git a/chrome/browser/ui/android/autofill/autofill_dialog_view_android.cc b/chrome/browser/ui/android/autofill/autofill_dialog_view_android.cc
index 09c3a9e28d29815f46395d659690fc3a3954e723..79ae43941fbab4ccb2b4e2ae5012ff24195e5551 100644
--- a/chrome/browser/ui/android/autofill/autofill_dialog_view_android.cc
+++ b/chrome/browser/ui/android/autofill/autofill_dialog_view_android.cc
@@ -104,7 +104,10 @@ void AutofillDialogViewAndroid::UpdateButtonStrip() {
NOTIMPLEMENTED();
}
-void AutofillDialogViewAndroid::UpdateSection(DialogSection section) {
+void AutofillDialogViewAndroid::UpdateSection(DialogSection section,
+ UserInputAction action) {
+ // TODO(estade): respect |action|.
+
JNIEnv* env = base::android::AttachCurrentThread();
const DetailInputs& updated_inputs =
controller_->RequestedFieldsForSection(section);
@@ -251,11 +254,11 @@ void AutofillDialogViewAndroid::ModelChanged() {
Java_AutofillDialogGlue_modelChanged(
env, java_object_.obj(),
controller_->ShouldShowSpinner());
- UpdateSection(SECTION_EMAIL);
- UpdateSection(SECTION_CC);
- UpdateSection(SECTION_BILLING);
- UpdateSection(SECTION_CC_BILLING);
- UpdateSection(SECTION_SHIPPING);
+ UpdateSection(SECTION_EMAIL, CLEAR_USER_INPUT);
+ UpdateSection(SECTION_CC, CLEAR_USER_INPUT);
+ UpdateSection(SECTION_BILLING, CLEAR_USER_INPUT);
+ UpdateSection(SECTION_CC_BILLING, CLEAR_USER_INPUT);
+ UpdateSection(SECTION_SHIPPING, CLEAR_USER_INPUT);
}
void AutofillDialogViewAndroid::SubmitForTesting() {

Powered by Google App Engine
This is Rietveld 408576698