去掉标题栏:
requestwindowfeature(window.feature_no_title);
api上是这么说的:
int feature_no_title flag for the “no title” feature, turning off the title at the top of the screen.
屏幕全屏:
getwindow().addflags(windowmanager.layoutparams.flag_fullscreen);
api上是这么说的:
int flag_fullscreen window flag: hide all screen decorations (e.g.
屏幕没有边界限制(允许窗口扩展到屏幕外):
getwindow().addflags(windowmanager.layoutparams.flag_layout_no_limits);
api上是这么说的:
int flag_layout_no_limits window flag: allow window to extend outside of the screen.
用法:
protected void oncreate(bundle savedinstancestate) {
// todo auto-generated method stub
super.oncreate(savedinstancestate);
requestwindowfeature(window.feature_no_title);
getwindow().addflags(windowmanager.layoutparams.flag_fullscreen);
getwindow().addflags(windowmanager.layoutparams.flag_layout_no_limits);
setcontentview(r.layout.newslists);
newslistlayout = findviewbyid(r.id.newslistlayout);
newslistlayout.setbackgroundcolor(color.magenta);
newsnamelist = (listview) findviewbyid(r.id.newsnamelist);
model = new model(0, 6);
namelistadapter = new newsnamelistadapter(this, model);
newsnamelist.setadapter(namelistadapter);
showpage = (textview) findviewbyid(r.id.newslistshowpage);
updatepage(model.getindex());
}
本文来自网络收集,不代表计算机技术网立场,如涉及侵权请联系管理员删除。
ctvol管理联系方式QQ:251552304
本文章地址:https://www.ctvol.com/addevelopment/939219.html