gpt4 book ai didi

android - Galaxy S10、S10+ 全屏模式

转载 作者:行者123 更新时间:2023-12-04 00:27:23 25 4
gpt4 key购买 nike

如何用三星 Galaxy S10 和 S10+ 实现全屏模式,以下代码对我不起作用:

getWindow().getDecorView().setSystemUiVisibility(
// Set the content to appear under the system bars so that the
// content doesn't resize when the system bars hide and show.
SYSTEM_UI_FLAG_LAYOUT_STABLE
| View.SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION
| View.SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN
// Hide the nav bar and status bar
// | View.SYSTEM_UI_FLAG_HIDE_NAVIGATION
| View.SYSTEM_UI_FLAG_FULLSCREEN
| View.SYSTEM_UI_FLAG_IMMERSIVE_STICKY
);

它隐藏了状态栏的内容,但它并没有隐藏它自己的状态栏:(

请帮忙

最佳答案

以您的应用程序的样式为我解决以下问题:

<item name="android:windowLayoutInDisplayCutoutMode">shortEdges</item>

有关支持抠图的更多详细信息,请查看:

https://developer.android.com/guide/topics/display-cutout

关于android - Galaxy S10、S10+ 全屏模式,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/55130940/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com