Android™ Immersive Full-Screen Mode
Posted on October 23, 2014
Let your Murl Engine app go truly full-screen. This is a quick reminder how to enable Androids™ immersive full-screen mode for Murl Engine apps. (updated 07.09.2018)
Please note that the immersive full-screen mode was introduced with Android™ 4.4 (API Level 19). Hence enabling the mode will only have effect on devices with Android™ 4.4 or higher.
To enable immersive full-screen mode add mHideNavigationBarImmersiveStickyEnabled=true;
to the murl.configdata
meta-data in your Android Manifest file:
</activity> <meta-data android:name="murl.configdata" android:value="mHideNavigationBarImmersiveStickyEnabled=true;"/> </application>
You can also set the the parameter in the common Makefile projekt/common/gnumake/module_yourapp.mk
to automatically include the setting when the Manifest file is created:
Doing so will enable immersive mode and set the immersive sticky flag. This will have the following effects to your Android™ app:
- Reminder Bubble
The system displays a reminder bubble the first time users enter immersive mode and reminds users how to display the system bars. - Full-Screen
Your app is displayed full screen without status bar and navigation bar. The usable screen size for your app increases to the actual screen size of the display allowing you to take advantage of every pixel on your screen (e.g. to 1920x1080 instead of 1794x1080 on a Nexus 5). - Sticky Immersion
An inward swipe in the system bars areas causes the bars to temporarily appear in a semi-transparent state. The bars automatically hide again after a short delay, or if the user interacts with the middle of the screen. The app content appears behind the system bars, so that the content doesn't resize as the system bars hide and show.
LTR reminder bubble, immersive full-screen, semi-transparent system bars
Instead of hiding the navigation bar you can also just dim it by enabling the "low profile" mode.
This feature is supported since Android™ 4.0 (API level 14) and can be accomplished by setting the value mLowProfileNavigationBarEnabled=true;
</activity> <meta-data android:name="murl.configdata" android:value="mLowProfileNavigationBarEnabled=true;"/> </application>MURL_ANDROID_CONFIG_DATA := mLowProfileNavigationBarEnabled=true;
LTR normal mode, low profile mode, immersive full-screen mode
If both modes are enabled, immersive full-screen mode will prevail. This means that you will see the immersive full-screen mode on devices with Android™ 4.4 or higher and the low profile mode on devices with Android™ version greater or equal 4.0 and lesser 4.4.
</activity> <meta-data android:name="murl.configdata" android:value="mLowProfileNavigationBarEnabled=true;mHideNavigationBarImmersiveStickyEnabled=true;"/> </application>MURL_ANDROID_CONFIG_DATA := mLowProfileNavigationBarEnabled=true;mHideNavigationBarImmersiveStickyEnabled=true;
An even easier way to enable the immersive full-screen mode is the use of the Dashboard and the Android / Configure Project command. The command will open a dialog window, where you can conveniently specify the most important Android™ settings including the desired screen mode. All changes made in the dialog will then be applied to the common Makefile. You have to rebuild the Manifest file to apply the changes (delete Manifest file and start gradle sync).
Android / Configure Project Dialog
Further information about the screen modes can be found in the section Managing the System UI of the Android™ developer documentation.
Don't miss out on any update,
subscribe to our newsletter.