| Index: ui/android/java/src/org/chromium/ui/base/ViewAndroidDelegate.java
|
| diff --git a/ui/android/java/src/org/chromium/ui/base/ViewAndroidDelegate.java b/ui/android/java/src/org/chromium/ui/base/ViewAndroidDelegate.java
|
| index 6d3694cc9bfe1304dd81fce41b8c3691be883f0a..77421498ef12d82854a153ca06f443b6aeaa03e0 100644
|
| --- a/ui/android/java/src/org/chromium/ui/base/ViewAndroidDelegate.java
|
| +++ b/ui/android/java/src/org/chromium/ui/base/ViewAndroidDelegate.java
|
| @@ -7,28 +7,33 @@ package org.chromium.ui.base;
|
| import android.view.View;
|
|
|
| /**
|
| - * Interface to acquire and release anchor views from the implementing View.
|
| + * Interface to add, remove, and position anchor views from the implementing View.
|
| */
|
| public interface ViewAndroidDelegate {
|
|
|
| /**
|
| - * @return An anchor view that can be used to anchor decoration views like Autofill popup.
|
| + * Add a view used to anchor decoration views like Autofill popup.
|
| + * @param anchorView The anchor view that needs to be added.
|
| */
|
| - View acquireAnchorView();
|
| + void addView(View anchorView);
|
|
|
| /**
|
| - * Set the anchor view to specified position and width (all units in dp).
|
| - * @param view The anchor view that needs to be positioned.
|
| + * Remove given anchor view.
|
| + * @param anchorView The anchor view that needs to be removed.
|
| + */
|
| + void removeView(View anchorView);
|
| +
|
| + /**
|
| + * Set the anchor view to specified position and width.
|
| + * @param anchorView The anchor view that needs to be positioned.
|
| * @param x X coordinate of the top left corner of the anchor view.
|
| * @param y Y coordinate of the top left corner of the anchor view.
|
| * @param width The width of the anchor view.
|
| * @param height The height of the anchor view.
|
| + * @param scale dip scale.
|
| + * @param leftMargin The left margin of the anchor view.
|
| + * @param topMargin The top margin of the anchor view.
|
| */
|
| - void setAnchorViewPosition(View view, float x, float y, float width, float height);
|
| -
|
| - /**
|
| - * Release given anchor view.
|
| - * @param anchorView The anchor view that needs to be released.
|
| - */
|
| - void releaseAnchorView(View anchorView);
|
| + void setViewPosition(View anchorView, float x, float y, float width, float height, float scale,
|
| + int leftMargin, int topMargin);
|
| }
|
|
|