How can we turn automatic brightness off in android?
Asked
Active
Viewed 6,737 times
1 Answers
23
Settings.System.putInt(getContentResolver(),
Settings.System.SCREEN_BRIGHTNESS_MODE, Settings.System.SCREEN_BRIGHTNESS_MODE_MANUAL);
-
4thanx Dusty to get idea i have done like this Settings.System.putInt(getContentResolver(), Settings.System.SCREEN_BRIGHTNESS_MODE, Settings.System.SCREEN_BRIGHTNESS_MODE_MANUAL); and got right result – shripal Oct 30 '10 at 06:13
-
No problem. You may want to accept the answer so anyone running across it will know it's been answered and not have click to see. Welcome to SO. – Dusty Oct 30 '10 at 13:53
-
Which package should be imported for this `Settings` and `SCREEN_BRIGHTNESS_MODE`? – Deqing Jan 06 '14 at 07:58
-
@Deqing, Settings is a default android library. Check here: http://developer.android.com/reference/android/provider/Settings.System.html – yuralife Jan 29 '14 at 12:02