鸿蒙harmonyos全屏显示,app全屏显示,取消标题栏和状态栏
deanyuancn
发布于 2021-8-5 18:35
浏览
4收藏
鸿蒙harmonyos全屏显示,app全屏显示,取消标题栏和状态栏
public class MainAbilitySlice extends AbilitySlice {
@Override
public void onStart(Intent intent) {
super.onStart(intent);
super.setUIContent(ResourceTable.Layout_ability_main);
getWindow().addFlags(WindowManager.LayoutConfig.MARK_FULL_SCREEN);
}
@Override
public void onActive() {
super.onActive();
}
@Override
public void onForeground(Intent intent) {
super.onForeground(intent);
}
}
"abilities": [
{
"metaData":{
"customizeData":[
{
"name": "hwc-theme",
"value": "androidhwext:style/Theme.Emui.Light.NoTitleBar",
"extra": ""
}
]
}
}
]
效果:
都看到这里了,解决了您问题的话不妨点个赞~谢谢老铁
已于2021-8-5 18:35:13修改
赞
3
收藏 4
回复
相关推荐
状态栏沉浸式(不隐藏状态栏):
ability中
config.json中
mark下,
感谢老铁的分享