设置 AlertDialog窗口的大小

来源:互联网 发布:中国对东盟投资数据 编辑:程序博客网 时间:2024/05/16 10:31

1)设置AlertDialog窗口大小的方法:

AlertDialog dialog = new AlertDialog.Builder(this).create();dialog.show();WindowManager.LayoutParams params = dialog.getWindow().getAttributes();params.width = 200;params.height = 200 ;dialog.getWindow().setAttributes(params);

2)去除边框

AlertDialog.setView(view,0,0,0,0);


1 0
原创粉丝点击