/**
* 隐藏虚拟按键,并且全屏
*/
protected void hideBottomUIMenu() {
//隐藏虚拟按键,并且全屏
if (Build.VERSION.SDK_INT > 11 && Build.VERSION.SDK_INT < 19) { // lower api
View v = this.getWindow().getDecorView();
v.setSystemUiVisibility(View.GONE);
} else if (Build.VERSION.SDK_INT >= 19) {
//for new api versions.
View decorView = getWindow().getDecorView();
int uiOptions = View.SYSTEM_UI_FLAG_HIDE_NAVIGATION
| View.SYSTEM_UI_FLAG_IMMERSIVE_STICKY | View.SYSTEM_UI_FLAG_FULLSCREEN;
decorView.setSystemUiVisibility(uiOptions);
}

}

  

相关文章:

  • 2021-12-22
  • 2021-08-15
  • 2021-08-24
  • 2022-03-07
  • 2022-12-23
  • 2021-11-27
  • 2021-09-11
  • 2022-02-07
猜你喜欢
  • 2021-06-22
  • 2021-06-23
  • 2022-12-23
  • 2021-05-11
  • 2021-07-16
  • 2022-12-23
相关资源
相似解决方案