0

My application is running landscape mode and I have set the following property of activity in manifest file

android:theme="@android:style/Theme.Black.NoTitleBar.Fullscreen"

It surely hides the notification bar when my activity is running. But when for suppose I launch browser activity from my app and returns, the notification bar is visible again. I am trying to find its solution nothing is working. I followed the following link but in vain. Hidden notification bar reappearing after screen lock and unlock Any idea?

Community
  • 1
  • 1
Khawar Raza
  • 15,870
  • 24
  • 70
  • 127

1 Answers1

0

I handle these things in my java code

        getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN,
                WindowManager.LayoutParams.FLAG_FULLSCREEN

The nice part of handling this in java is you can release those flags at any time to get rid of full screen. I put this before setContent but I can't recall if that it required or not.

If this doesn't keep it fullscreen you could try to put it in the onResume(), which is my guess how your losing it.

MinceMan
  • 7,483
  • 3
  • 38
  • 40