Android 4.4 (API Level 19) introduces a new
Following picture illustrates the different "immersive mode" states:
- Non-immersive mode—This is how the app appears before it enters immersive mode. It is also how the app appears if you use the
IMMERSIVEflag, and the user swipes to display the system bars.
- Reminder bubble—The system displays a reminder bubble the first time users enter immersive mode in your app. The reminder bubble reminds users how to display the system bars.
Note: If you want to force the reminder bubble to appear for testing purposes, you can do so by putting the app in immersive mode, turning off the screen with the power button, and then turning the screen back on again within 5 seconds.
- Immersive mode—This is the app in immersive mode, with the system bars and other UI controls hidden.
- Sticky flag—This is the UI you see if you use the
IMMERSIVE_STICKYflag, and the user swipes to display the system bars. Semi-transparent bars temporarily appear and then hide again. The act of swiping doesn't clear any flags, nor does it trigger your system UI visibility change listeners, because the transient appearance of the system bars isn't considered a UI visibility change.
To enable Immersive mode you should call:
It will use
IMMERSIVE_STICKY flag. If user has Android versision less than Android 4.4 (API Level 19) call will be ignored, so you do not hav to do any additional check. Just call in on your app start, and your game will run in immersive mode if it's possible.
API use example can be founded in AnOtherFeaturesPreview.cs file.