Android 隐藏顶部菜单栏
Android 隐藏状态栏
在Activity中:
getWindow().addFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN);
在fragment中
getActivity().getWindow().addFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN);
显示:
getWindow().clearFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN)