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

Unified Diff: android_webview/java/src/org/chromium/android_webview/AwAutofillClient.java

Issue 2103243002: Factor out ContentViewAndroidDelegate (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased Created 4 years, 5 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: android_webview/java/src/org/chromium/android_webview/AwAutofillClient.java
diff --git a/android_webview/java/src/org/chromium/android_webview/AwAutofillClient.java b/android_webview/java/src/org/chromium/android_webview/AwAutofillClient.java
index 172c2b384f03a6bb2115075cda180d040e5b34fb..c3bd28d3030a70d7d135c2fa83340b4659bfa99f 100644
--- a/android_webview/java/src/org/chromium/android_webview/AwAutofillClient.java
+++ b/android_webview/java/src/org/chromium/android_webview/AwAutofillClient.java
@@ -4,6 +4,7 @@
package org.chromium.android_webview;
+import android.view.View;
import android.view.ViewGroup;
import org.chromium.base.annotations.CalledByNative;
@@ -41,15 +42,16 @@ public class AwAutofillClient {
}
@CalledByNative
- private void showAutofillPopup(float x, float y, float width, float height,
- boolean isRtl, AutofillSuggestion[] suggestions) {
+ private void showAutofillPopup(View anchorView, float width, boolean isRtl,
+ AutofillSuggestion[] suggestions) {
if (mContentViewCore == null) return;
if (mAutofillPopup == null) {
mAutofillPopup = new AutofillPopup(
mContentViewCore.getContext(),
- mContentViewCore.getViewAndroidDelegate(),
+ anchorView,
+ width,
new AutofillDelegate() {
@Override
public void dismissed() { }
@@ -61,7 +63,6 @@ public class AwAutofillClient {
public void deleteSuggestion(int listIndex) { }
});
}
- mAutofillPopup.setAnchorRect(x, y, width, height);
mAutofillPopup.filterAndShow(suggestions, isRtl);
}

Powered by Google App Engine
This is Rietveld 408576698