Amazon Gift Cards

Sunday, May 24, 2009

Changing the Screen Brightness Programatically in Cupcake

Previously we had blogged about on how to change the screen brightness in android pre cupcake and on cupcake, the android team had added an official way to change the brightness without the hacks. Here is how to use it:

WindowManager.LayoutParams lp = getWindow().getAttributes();
lp.screenBrightness = 100 / 100.0f;


Update History
   Jan 17, 2012 - Visual Update
Post a Comment