mirror of
https://github.com/Tencent/QMUI_Android.git
synced 2026-10-26 09:39:26 +08:00
bugfix: xiaomi android p notch fullscreen
This commit is contained in:
@@ -67,6 +67,11 @@ public class QMUIStatusBarHelper {
|
||||
// 版本小于4.4,绝对不考虑沉浸式
|
||||
return;
|
||||
}
|
||||
|
||||
if (QMUINotchHelper.isNotchOfficialSupport()) {
|
||||
handleDisplayCutoutMode(window);
|
||||
}
|
||||
|
||||
// 小米和魅族4.4 以上版本支持沉浸式
|
||||
if (QMUIDeviceHelper.isMeizu() || QMUIDeviceHelper.isMIUI()) {
|
||||
window.setFlags(WindowManager.LayoutParams.FLAG_TRANSLUCENT_STATUS,
|
||||
@@ -74,10 +79,6 @@ public class QMUIStatusBarHelper {
|
||||
return;
|
||||
}
|
||||
|
||||
if (QMUINotchHelper.isNotchOfficialSupport()) {
|
||||
handleDisplayCutoutMode(window);
|
||||
}
|
||||
|
||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) {
|
||||
window.getDecorView().setSystemUiVisibility(View.SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN
|
||||
| View.SYSTEM_UI_FLAG_LAYOUT_STABLE);
|
||||
|
||||
Reference in New Issue
Block a user