本文整理汇总了Java中org.chromium.ui.ViewAndroidDelegate类的典型用法代码示例。如果您正苦于以下问题:Java ViewAndroidDelegate类的具体用法?Java ViewAndroidDelegate怎么用?Java ViewAndroidDelegate使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
ViewAndroidDelegate类属于org.chromium.ui包,在下文中一共展示了ViewAndroidDelegate类的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: AutofillPopup
import org.chromium.ui.ViewAndroidDelegate; //导入依赖的package包/类
/**
* Creates an AutofillWindow with specified parameters.
* @param context Application context.
* @param viewAndroidDelegate View delegate used to add and remove views.
* @param autofillCallback A object that handles the calls to the native AutofillPopupView.
*/
public AutofillPopup(Context context, ViewAndroidDelegate viewAndroidDelegate,
AutofillPopupDelegate autofillCallback) {
super(context, null, 0, R.style.AutofillPopupWindow);
mContext = context;
mViewAndroidDelegate = viewAndroidDelegate ;
mAutofillCallback = autofillCallback;
setOnItemClickListener(this);
mAnchorView = mViewAndroidDelegate.acquireAnchorView();
mAnchorView.setId(R.id.autofill_popup_window);
mAnchorView.setTag(this);
mViewAndroidDelegate.setAnchorViewPosition(mAnchorView, mAnchorX, mAnchorY, mAnchorWidth,
mAnchorHeight);
mLayoutChangeListener = new OnLayoutChangeListener() {
@Override
public void onLayoutChange(View v, int left, int top, int right, int bottom,
int oldLeft, int oldTop, int oldRight, int oldBottom) {
if (v == mAnchorView) AutofillPopup.this.show();
}
};
mAnchorView.addOnLayoutChangeListener(mLayoutChangeListener);
setAnchorView(mAnchorView);
}
示例2: ViewAndroid
import org.chromium.ui.ViewAndroidDelegate; //导入依赖的package包/类
/**
* Constructs a View object.
*/
public ViewAndroid(WindowAndroid nativeWindow, ViewAndroidDelegate viewAndroidDelegate) {
mWindowAndroid = nativeWindow;
mViewAndroidDelegate = viewAndroidDelegate;
mNativeViewAndroid = nativeInit(mWindowAndroid.getNativePointer());
}
示例3: getViewAndroidDelegate
import org.chromium.ui.ViewAndroidDelegate; //导入依赖的package包/类
public ViewAndroidDelegate getViewAndroidDelegate() {
return mViewAndroidDelegate;
}
示例4: AutofillPopupGlue
import org.chromium.ui.ViewAndroidDelegate; //导入依赖的package包/类
public AutofillPopupGlue(int nativeAutofillPopupViewAndroid, WindowAndroid windowAndroid,
ViewAndroidDelegate containerViewDelegate) {
mNativeAutofillPopup = nativeAutofillPopupViewAndroid;
mAutofillPopup = new AutofillPopup(windowAndroid.getContext(), containerViewDelegate, this);
}