1

Is there a way in ICS or Honeycomb to go completely full screen? I want the system UI completely gone! Currently what I do is:

    requestWindowFeature(Window.FEATURE_NO_TITLE);
    getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN, 
                            WindowManager.LayoutParams.FLAG_FULLSCREEN);

    setContentView(R.layout.main);
    getWindow().getDecorView().setSystemUiVisibility(View.STATUS_BAR_HIDDEN);

But this results in the Status Bar being replaced by really dim dots! I want it completely gone! Lets say for example I want to play a video or show a picture that takes up the whole screen. I'm okay with the status bar coming back on user interaction but I need it completely gone when there is no user interaction.

With the code above. I get the following look:

Status bar hidden replaced by dim dots

I want the dim dots gone as well and my video / image to be completely full screen.

Ali
  • 12,354
  • 9
  • 54
  • 83
  • Similar to http://stackoverflow.com/questions/8469112/hide-ics-back-home-task-switcher-buttons/8481777#8481777 at least for ICS – NKijak Mar 30 '12 at 03:45

4 Answers4

3

This is not possible in Honeycomb, but has been added in API v14. Use:

getWindow().getDecorView().setSystemUiVisibility(View.SYSTEM_UI_FLAG_HIDE_NAVIGATION);

See the more detailed answers over here (though I would use a Build.Version.SDK_INT check instead of the suggested reflection-based check for support):

Hide ICS back home task switcher buttons

Community
  • 1
  • 1
P.T.
  • 24,557
  • 7
  • 64
  • 95
1

The last information I have is that you can use the black tape to cover it. That's the suggestion given by Chet Haase. Watch this google IO 2011 session Q&A starting at 53minutes

Win Myo Htet
  • 5,377
  • 3
  • 38
  • 56
  • Well, I managed to do it my manually stopping the `System UI` service. However the question now become is that can I stop this service through my code? Apparently the class is called `StatusBarService` but it's not visible to us. – Ali Mar 30 '12 at 01:32
1

As the previous poster Suggested, that is completely impossible without rooting your device and performing some somewhat dirty process kill operations. The reason for is that new Hardware (like a tablet, for instance) may not have hardware buttons for navigation - and so by hiding those buttons the User would have no means of doing things that they are supposed to be guaranteed to be able to do, like going to the home screen, or accessing device info. Whether or not you might agree with that reasoning, such is the API.

JRaymond
  • 11,625
  • 5
  • 37
  • 40
  • Well, for my purposes I'm okay with the rooting option, do you know how to kill the service on a rooted device? – Ali Mar 30 '12 at 01:33
  • Sure... heres a blog post about it, at least for honeycomb, but I doubt they would have patched it for ICS http://android.serverbox.ch/?p=306 – JRaymond Mar 30 '12 at 01:36
0

You want SYSTEM_UI_FLAG_HIDE_NAVIGATION . Keep in mind that since the soft navigation buttons are key to device experience this only hides the buttons until there is some user interaction. If you want to permanently hide them then rooting the device (as others have suggested) is the only way to go.

The flag was added as of Ice Cream Sandwich, API 14. Previous to 14 a flag STATUS_BAR_HIDDEN was added in Honeycomb, API 11 that had a similar function. Previous to that the soft navigation buttons didn't exist, so fullscreen modes were handled entirely by Themes (specifically Theme.NoTitleBar.Fullscreen).

Use:

if( Build.VERSION.SDK_INT >= Build.VERSION_CODES.ICE_CREAM_SANDWICH )
    mBaseLayout.setSystemUiVisibility( View.SYSTEM_UI_FLAG_HIDE_NAVIGATION );
else if( Build.VERSION.SDK_INT >= Build.VERSION_CODES.HONEYCOMB )
    mBaseLayout.setSystemUiVisibility( View.STATUS_BAR_HIDDEN );
reor
  • 820
  • 9
  • 22