Index: chrome/browser/ui/android/autofill/autofill_keyboard_accessory_view.h |
diff --git a/chrome/browser/ui/android/autofill/autofill_popup_view_android.h b/chrome/browser/ui/android/autofill/autofill_keyboard_accessory_view.h |
similarity index 56% |
copy from chrome/browser/ui/android/autofill/autofill_popup_view_android.h |
copy to chrome/browser/ui/android/autofill/autofill_keyboard_accessory_view.h |
index 8d4211bea31baa21734e3f82185d96016e32d652..a146b38e16eb85757b139bfa111ef67704d8d713 100644 |
--- a/chrome/browser/ui/android/autofill/autofill_popup_view_android.h |
+++ b/chrome/browser/ui/android/autofill/autofill_keyboard_accessory_view.h |
@@ -2,8 +2,8 @@ |
// Use of this source code is governed by a BSD-style license that can be |
// found in the LICENSE file. |
-#ifndef CHROME_BROWSER_UI_ANDROID_AUTOFILL_AUTOFILL_POPUP_VIEW_ANDROID_H_ |
-#define CHROME_BROWSER_UI_ANDROID_AUTOFILL_AUTOFILL_POPUP_VIEW_ANDROID_H_ |
+#ifndef CHROME_BROWSER_UI_ANDROID_AUTOFILL_AUTOFILL_KEYBOARD_ACCESSORY_VIEW_H_ |
+#define CHROME_BROWSER_UI_ANDROID_AUTOFILL_AUTOFILL_KEYBOARD_ACCESSORY_VIEW_H_ |
#include <jni.h> |
@@ -19,9 +19,13 @@ namespace autofill { |
class AutofillPopupController; |
-class AutofillPopupViewAndroid : public AutofillPopupView { |
+// A suggestion view that acts as an alternative to the field-attached popup |
+// window. This view appears above the keyboard and spans the width of the |
+// screen, condensing rather than overlaying the content area. Enable via |
+// --enable-autofill-keyboard-accessory-view. |
+class AutofillKeyboardAccessoryView : public AutofillPopupView { |
public: |
- explicit AutofillPopupViewAndroid(AutofillPopupController* controller); |
+ explicit AutofillKeyboardAccessoryView(AutofillPopupController* controller); |
// -------------------------------------------------------------------------- |
// Methods called from Java via JNI |
@@ -29,9 +33,9 @@ class AutofillPopupViewAndroid : public AutofillPopupView { |
// Called when an autofill item was selected. |
void SuggestionSelected(JNIEnv* env, jobject obj, jint list_index); |
- void PopupDismissed(JNIEnv* env, jobject obj); |
+ void ViewDismissed(JNIEnv* env, jobject obj); |
- static bool RegisterAutofillPopupViewAndroid(JNIEnv* env); |
+ static bool RegisterAutofillKeyboardAccessoryView(JNIEnv* env); |
protected: |
// AutofillPopupView implementation. |
@@ -41,16 +45,16 @@ class AutofillPopupViewAndroid : public AutofillPopupView { |
void UpdateBoundsAndRedrawPopup() override; |
private: |
- ~AutofillPopupViewAndroid() override; |
+ ~AutofillKeyboardAccessoryView() override; |
AutofillPopupController* controller_; // weak. |
// The corresponding java object. |
base::android::ScopedJavaGlobalRef<jobject> java_object_; |
- DISALLOW_COPY_AND_ASSIGN(AutofillPopupViewAndroid); |
+ DISALLOW_COPY_AND_ASSIGN(AutofillKeyboardAccessoryView); |
}; |
} // namespace autofill |
-#endif // CHROME_BROWSER_UI_ANDROID_AUTOFILL_AUTOFILL_POPUP_VIEW_ANDROID_H_ |
+#endif // CHROME_BROWSER_UI_ANDROID_AUTOFILL_AUTOFILL_KEYBOARD_ACCESSORY_VIEW_H_ |