本文整理了Java中android.widget.PopupWindow.setWindowLayoutType()
方法的一些代码示例,展示了PopupWindow.setWindowLayoutType()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。PopupWindow.setWindowLayoutType()
方法的具体详情如下:
包路径:android.widget.PopupWindow
类名称:PopupWindow
方法名:setWindowLayoutType
暂无
代码示例来源:origin: stackoverflow.com
pw.setWindowLayoutType(WindowManager.LayoutParams.TYPE_TOAST);
pw.showAtLocation(layout, Gravity.CENTER | Gravity.TOP, 0, 500);
代码示例来源:origin: osfans/trime
@Override
public View onCreateCandidatesView() {
LayoutInflater inflater = getLayoutInflater();
mCompositionContainer =
(LinearLayout) inflater.inflate(R.layout.composition_container, (ViewGroup) null);
hideComposition();
mFloatingWindow = new PopupWindow(mCompositionContainer);
mFloatingWindow.setClippingEnabled(false);
mFloatingWindow.setInputMethodMode(PopupWindow.INPUT_METHOD_NOT_NEEDED);
mFloatingWindow.setWindowLayoutType(getDialogType());
mComposition = (Composition) mCompositionContainer.getChildAt(0);
mCandidateContainer =
(FrameLayout) inflater.inflate(R.layout.candidate_container, (ViewGroup) null);
mCandidate = (Candidate) mCandidateContainer.findViewById(R.id.candidate);
mCandidate.setCandidateListener(this);
setShowComment(!Rime.getOption("_hide_comment"));
mCandidate.setVisibility(!Rime.getOption("_hide_candidate") ? View.VISIBLE : View.GONE);
loadBackground();
return mCandidateContainer;
}
内容来源于网络,如有侵权,请联系作者删除!