android 应用级别 亮度调节

        Window localWindow = getWindow();
        WindowManager.LayoutParams localLayoutParams = localWindow.getAttributes();
        localLayoutParams.screenBrightness = 0.5.0f;  //(范围0-1, 值为-1时是自动调节)
        localWindow.setAttributes(localLayoutParams);

posted @ 2013-06-09 20:35  爱生活,爱编程  阅读(181)  评论(0)    收藏  举报