Is there a way to hide the system bar in Android 3.0? It's an internal device and I'm managing navigation

velazcod picture velazcod · Feb 24, 2011 · Viewed 30.4k times · Source

In Android 2.3 and below, you could make an application full screen, and then "hijack" the menu/back/search buttons by just returning false onKeyDown()... and registering the app as a default home launcher application, that way, there's no way to exit the application.

In Android 3.0 (Honeycomb) the navigation buttons (System Bar) is always present, I'd like to hide it. Is it possible?

FYI, I am not publishing this application on the Android Market. This is an internal application for devices that are going to be used internally, I need to secure the device.

Answer

velazcod picture velazcod · May 10, 2011

Since this is not possible to do using a public API, I have found a way to do it in a very "hack-ish" way that requires a rooted device.

Update: as user864555 pointed below, this is another solution

$ adb remount
$ adb shell mv /system/app/SystemUI.odex /system/app/SystemUI.odexold
$ adb shell mv /system/app/SystemUI.apk /system/app/SystemUI.apkold
$ adb reboot

"That code disable the app SystemUI which is the actually menu bar. Which that modification, you will also gain the space of that system bar. But make sure to have a back button or something to exit."

That works great as well. Please vote for his answer. I will try to keep this one updated as much as I can.


Update: Here's a third method. A way to do it programmatically or using the command line. Found here: http://android.serverbox.ch/?p=306

This method requires root access, but you don't need to change the LCD Density, keeping the same as the original, and you can get the UI nav bar back really quick and easy without having to reboot everytime.

The blog post also shows how to implement it on your Android application, remember it requires root, and it might not be a great idea to do so unless your application is running on a kiosk or your own device, please do not implement this method on an app that's published in the Android market or anywhere public.

To stop/remove/disable the system bar (need to be su before issuing this command):

$ service call activity 79 s16 com.android.systemui

To restore the system bar just simply issue this command:

$ am startservice -n com.android.systemui/.SystemUIService

It's that easy. Hopefully ICS gets released soon along with the source code so that anyone can build Android for our Kiosk tablets.