Android用代码实现全屏,android代码全屏, public v
分享于 点击 31626 次 点评:165
Android用代码实现全屏,android代码全屏, public v
public void toggleFullscreen(boolean fullScreen) { //fullScreen为true时全屏,否则相反 WindowManager.LayoutParams attrs = getWindow().getAttributes(); if (fullScreen) { attrs.flags |= WindowManager.LayoutParams.FLAG_FULLSCREEN; } else { attrs.flags &= ~WindowManager.LayoutParams.FLAG_FULLSCREEN; } getWindow().setAttributes(attrs); }
用户点评