Android Question Notch and video player

Sasuke Sama

Active Member
Licensed User
Im using exoplayer and i want to know if its possible to make exoplayer somehow to extend to the notch and display the video in the entire screen.


Staff member
Licensed User
It might be possible to do on Android 9+. There are no APIs for this on older versions.

Sasuke Sama

Active Member
Licensed User
Try this:
Sub Activity_Create(FirstTime As Boolean)
   Dim p As Phone
   If p.SdkVersion >= 28 Then
       Dim jo As JavaObject
       jo = jo.RunMethod("getWindow", Null)
       jo.RunMethodJO("getAttributes", Null).SetField("layoutInDisplayCutoutMode", 1)
   End If
End Sub
its kinda works but not as expected.
the layout dose extands to the notch ( the statebar backgroundcolor mathes the layout color) but any view such as image view or the exoplayer still stops to the notch