Options for specifying different types of system UI elements that generate window insets.
Use this enum with PlayerSettings.Android.requestedVisibleInsets to specify whether the status bar, navigation bar, both, or none are visible by default when your application starts. Use it with PlayerSettings.Android.requestedOverlappingInsets to specify which of those bars, and the caption bar, your application window extends behind.
Note: The system controls the visibility of the caption bar, so PlayerSettings.Android.requestedVisibleInsets has no effect on it.
using UnityEditor;
public class ApplyInsets { public static void Setup() { // Request status and navigation bars to be visible for the application. PlayerSettings.Android.requestedVisibleInsets = AndroidWindowInsetsType.NavigationBars | AndroidWindowInsetsType.StatusBars; } }
| Property | Description |
|---|---|
| None | No inset type selected. |
| StatusBars | Represents the area of the screen the system status bar occupies at the top of the screen. |
| NavigationBars | Represents the area of the screen the system navigation elements occupy. |
| CaptionBar | Represents the area of the screen the caption bar occupies at the top of the application window. |