Android应用程序全屏显示方法

时间:2014-05-13 23:19:51   收藏:0   阅读:509

导入两个包:

import android.view.Window;
import android.view.WindowManager;

public class MainActivity extends ActionBarActivity 
{
	@Override
    protected void onCreate(Bundle savedInstanceState) 
	{
        super.onCreate(savedInstanceState);
        this.requestWindowFeature(Window.FEATURE_NO_TITLE);	//设置程序不显示标题
        this.getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN, 
                WindowManager.LayoutParams.FLAG_FULLSCREEN);	//设置不显示状态栏
        setContentView(R.layout.activity_main);

    }

}



Android应用程序全屏显示方法,布布扣,bubuko.com

评论(0
© 2014 mamicode.com 版权所有 京ICP备13008772号-2  联系我们:gaon5@hotmail.com
迷上了代码!