怎么实现弹出popuwindow之后父界面变暗
1个回答
2016-10-02
展开全部
PopupWindow mPopupSkb;
PopUpView popupview = new PopUpView(mContext, null);
popupview.setBackgroundDrawable((getResources().getDrawable(R.drawable.textinput_predictive_popup_bg)));
mPopupSkb = new PopupWindow(popupview, LayoutParams.FILL_PARENT, LayoutParams.FILL_PARENT);
mPopupSkb.setOutsideTouchable(false);
mPopupSkb.setContentView(popupview);
ColorDrawable color = new ColorDrawable(-10000);
mPopupSkb.setBackgroundDrawable(color);
mPopupSkb.update();
mPopupSkb.showAtLocation(mSkbContainer, Gravity.CENTER, 50, 300);
我是这样做的, 但是我发现虽然设置成了LayoutParams.FILL_PARENT,
还是显示的半屏幕,只显示了半个粉色的屏幕
PopUpView popupview = new PopUpView(mContext, null);
popupview.setBackgroundDrawable((getResources().getDrawable(R.drawable.textinput_predictive_popup_bg)));
mPopupSkb = new PopupWindow(popupview, LayoutParams.FILL_PARENT, LayoutParams.FILL_PARENT);
mPopupSkb.setOutsideTouchable(false);
mPopupSkb.setContentView(popupview);
ColorDrawable color = new ColorDrawable(-10000);
mPopupSkb.setBackgroundDrawable(color);
mPopupSkb.update();
mPopupSkb.showAtLocation(mSkbContainer, Gravity.CENTER, 50, 300);
我是这样做的, 但是我发现虽然设置成了LayoutParams.FILL_PARENT,
还是显示的半屏幕,只显示了半个粉色的屏幕
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询