6

I've removed the status bar which shows network, battery and time information in Android by take off the background image. But the icons are still there. Just wanna know how to remove the battery icon as well.

Not for apps but for framework development. Thanks in advance.

Jarmie
  • 75
  • 1
  • 1
  • 5
  • What for do you need this? Tell us more about your app – Egor Aug 03 '11 at 07:15
  • I'm not developing app... It's for a new product. Thus I have to design an entirely new UI and remove the things I don't need for keeping it clean. – Jarmie Aug 04 '11 at 02:48

2 Answers2

6

Have you tried to call

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

in Activity onCreate() ?

Maxim
  • 2,996
  • 17
  • 19
  • Sorry for that I did not make the description clear enough. I'm not writing an app but for developing a kind of special framework. Thanks for the efficient reply anyway. Any other suggestion? – Jarmie Aug 03 '11 at 07:36
  • Question Owner did not want this. Anyway I exactly want this so Voted up for it – Inzimam Tariq IT Nov 27 '15 at 21:25
4

If you are working on Android 2.2, you can remove it by the following step.

  1. Find StatusBarPolicy.java
  2. Find mBatteryIcon and add service.setIconVisibility(mBatteryIcon , false); for it.
  3. Remove all actions relevant to battery in the intent-filter
Jett Hsieh
  • 3,159
  • 27
  • 33