Is there a way to determine if Android app is running full screen?

后端 未结 10 1932
春和景丽
春和景丽 2020-12-31 04:17

i was just wondering if there was a simple way to see if an application running on android is currently in full screen. is there a way to query android to see if you\'re cu

10条回答
  •  甜味超标
    2020-12-31 04:22

    Just to complete on Sigwann answer:

    boolean fullScreen = (getWindow().getAttributes().flags & WindowManager.LayoutParams.FLAG_FULLSCREEN) != 0;
    boolean forceNotFullScreen = (getWindow().getAttributes().flags & WindowManager.LayoutParams.FLAG_FORCE_NOT_FULLSCREEN) != 0;
    boolean actionbarVisible = getActionBar().isShowing();
    

提交回复
热议问题