This is indeed frustrating. however, there's a funny new
wrinkle whenever I use the new cupcake-approved sugar-free method,
the brightness stays after I go back to the home screen. (yay) I seem
to have problems when brightness gets too low though (IE, cant do
anything with the unit ...
It must still be possible in 1.5 cupcake:
- PowerManager can set it
- Settings - SoundDisplay - Brightness can change it
- haven't checked Locale
While the system setting might have privileged access to the API, the
PowerManager is just a normal program. So how do they do it?
On Thu, Apr 23, 2009 at 9:34 PM, coredump jose.jun...@gmail.com wrote:
So I tried the 'correct' way to do it:
Settings.System.putInt(getContentResolver(),
Settings.System.SCREEN_BRIGHTNESS, 255);
And it doesnt work. It seems to change the brightness value on the
Display Settings Screen
So I tried the 'correct' way to do it:
Settings.System.putInt(getContentResolver(),
Settings.System.SCREEN_BRIGHTNESS, 255);
And it doesnt work. It seems to change the brightness value on the
Display Settings Screen but not the actual display brightness. I tried
with putString too, no game.
I
hmm but i also dont like that so much.
for example right now i was thinking to write a simple app just
changing the brightness
in a simple way. not just for a window, for the whole system.
Often I am out and just like a simple change brightness, without
searching through
the setup (imagine i am
// Make the screen full bright for this activity.
WindowManager.LayoutParams lp = getWindow().getAttributes();
lp.screenBrightness = 1.0f;
getWindow().setAttributes(lp);
On Wed, Apr 15, 2009 at 10:21 PM, SR stan.r...@gmail.com wrote:
Dianne,
Would you mind
Dianne,
Would you mind sharing a snippet of code on how to do this in Cupcake
using the new API?
Thanks!
Stan
On Apr 8, 3:49 pm, Dianne Hackborn hack...@android.com wrote:
There is a new API to be able to force the screen brightness while your
window is on-screen.
On Wed, Apr 8, 2009 at
Ah, that makes sense. Thank you.
On Apr 8, 4:45 pm, Dianne Hackborn hack...@android.com wrote:
It will only modify the screen while that window/activity is being shown to
the user. This allows it to be done in a safe way (no permission required)
which the system can recover from if there is
Dianne,
Is there a new way to do this in Cupcake, or is the functionality
being removed?
On Mar 23, 1:37 pm, Dianne Hackborn hack...@android.com wrote:
This is a private API and will break in Cupcake.
--
Dianne Hackborn
Android framework engineer
hack...@android.com
There is a new API to be able to force the screen brightness while your
window is on-screen.
On Wed, Apr 8, 2009 at 12:08 PM, Todd Sjolander guyfantas...@gmail.comwrote:
Dianne,
Is there a new way to do this in Cupcake, or is the functionality
being removed?
On Mar 23, 1:37 pm, Dianne
It will only modify the screen while that window/activity is being shown to
the user. This allows it to be done in a safe way (no permission required)
which the system can recover from if there is a bug in the application (or
if the application gets killed for some reason, as we tend to do).
On
On Sun, Mar 22, 2009 at 10:45 PM, joby joby...@gmail.com wrote:
IHardwareService hardware = IHardwareService.Stub.asInterface
(
ServiceManager.getService(hardware));
try {
hardware.setScreenBacklight(150);
} catch (RemoteException e)
// TODO
i tried with the below code but its not effecting
Settings.System.putInt(ftaContext.getContentResolver(),
Settings.System.SCREEN_BRIGHTNESS, bright);
but i got the screen brightness by the below code
IHardwareService hardware = IHardwareService.Stub.asInterface
(
and to read it and log it:
int ib = Settings.System.getInt(getContentResolver(),
Settings.System.SCREEN_BRIGHTNESS,-1);
Log.d(SCREEN_BRIGHTNESS (0-255) {+ib+});
On Mar 20, 6:53 pm, mark.ka...@gmail.com wrote:
int bright = 50;
make that
Log.d(x...@#$% tag :-),SCREEN_BRIGHTNESS (0-255) {+ib+});
serge
On Mar 21, 10:40 am, sm1 sergemas...@gmail.com wrote:
and to read it and log it:
int ib = Settings.System.getInt(getContentResolver(),
Settings.System.SCREEN_BRIGHTNESS,-1);
int bright = 50;
Settings.System.putInt(ftaContext.getContentResolver(),
Settings.System.SCREEN_BRIGHTNESS, bright);
On Mar 19, 9:14 pm, joby joby...@gmail.com wrote:
Hi,
I want to use the system brightness in android,anybody can give
me a sample code of getting the brightness from
16 matches
Mail list logo