Android:MATCH_PARENT vs FLAG_FULLSCREEN

时间:2016-09-16 23:30:53

标签: android view

LayoutParams.MATCH_PARENTLayoutParams.FLAG_FULLSCREEN之间有什么区别?虽然两者都给出了相同的结果!

ViewGroup.LayoutParams.MATCH_PARENT

match_parent

WindowManager.LayoutParams.FLAG_FULLSCREEN

fullscreen

示例:

Dialog dialog = new Dialog(this, LayoutParams.MATCH_PARENT);
Dialog dialog = new Dialog(this, WindowManager.LayoutParams.FLAG_FULLSCREEN));

1 个答案:

答案 0 :(得分:2)

MATCH_PARENT用于填充父级。

FLAG_FULLSCREEN用于制作全屏窗口。 (隐藏状态栏)