How can i set Brightness value while the activity style is Theme.NoDisplay?
<p>1.First i set the activity style is NODisplay in manifest.xml use the follow code</p>

<pre><code>android:theme="@android:style/Theme.NoDisplay"
</code></pre>

<p>2.I set brightness value use the follow code :</p>

<pre><code>public void setBrightness(Activity activity,int brightness){

       WindowManager.LayoutParams lparams = activity.getWindow().getAttributes();
       lparams.screenBrightness = Float.valueOf(brightness) * (1f / 255);
       activity.getWindow().setAttributes(lparams);
}
</code></pre>

<p>Program can perform,but the brightness has not changed.   </p>

<p>What is the reason?</p>

<p>Does anyone have any idea about it? Thanks for any help !</p>
