透明度设置:
WindowManager.LayoutParams lp=this.getWindow().getAttributes();
lp.dimAmount=0.5f;
this.getWindow().setAttributes(lp);
this.getWindow().addFlags(WindowManager.LayoutParams.FLAG_DIM_BEHIND);
个人感觉0.5效果最佳,越大则越暗。