0

I have an Android app which allows the user to change the color of a background based on the selection they choose.

This is the line that changes the color:

appBackground.setBackgroundColor(Color.rgb(inRed, inGreen, inBlue));

How do I also change the menu bar color as well the notification bar to change to that color of the user's choice?

I know it's only possible in KitKat but can someone point me to the way...

Si8
  • 9,141
  • 22
  • 109
  • 221

1 Answers1

0

If you would like an effect like the image below, have a look here: Why can't we use a Translucent system bars with and ActionBar

As you can see, the background color can be changed programatically (so it's not defined in the xml).

Image

Community
  • 1
  • 1
Mdlc
  • 7,128
  • 12
  • 55
  • 98