If Ph.SdkVersion>= 28 Then
Dim jo As JavaObject
jo.InitializeContext
jo = jo.RunMethod("getWindow", Null)
jo.RunMethodJO("getAttributes", Null).SetField("layoutInDisplayCutoutMode",LAYOUT_IN_DISPLAY_CUTOUT_MODE_SHORT_EDGES)
If GetNotchHeight > 0 Then
bIsNotch = True
Else
bIsNotch = False
End If
If iDisplayNotch = NOTCH_NEVER Then
jo.RunMethodJO("getAttributes", Null).SetField("layoutInDisplayCutoutMode", LAYOUT_IN_DISPLAY_CUTOUT_MODE_NEVER)
Else
jo.RunMethodJO("getAttributes", Null).SetField("layoutInDisplayCutoutMode",LAYOUT_IN_DISPLAY_CUTOUT_MODE_SHORT_EDGES)
End If
End If