Need help,Screen didn't turn on after I change Activity's theme
<p>I'm making my alarm app. There is  an Activity to show alarm infomation.
I want turn on the screen and unlock it. I wrote these code</p>

<p><b>AlarmActivity.java:</b></p>

<pre>
public class AlarmActivity extends Activity {
  ......
  void onCreate(Bundle bl) {
    .....
    final Window win = getWindow();
    win.requestFeature(android.view.Window.FEATURE_NO_TITLE);   
    win.addFlags(WindowManager.LayoutParams.FLAG_SHOW_WHEN_LOCKED
               | WindowManager.LayoutParams.FLAG_DISMISS_KEYGUARD
               | WindowManager.LayoutParams.FLAG_KEEP_SCREEN_ON
               | WindowManager.LayoutParams.FLAG_TURN_SCREEN_ON);

    LayoutInflater inflater = LayoutInflater.from(this);
    setContentView(inflater.inflate(R.layout.alarm, null));
  }

  ......
}  
</pre>

<p><b>AndroidManifest.xml</b></p>

<pre>
{activity android:name="AlarmTaskActivity"
                android:excludeFromRecents="true"
                android:theme="@android:style/Theme.Wallpaper.NoTitleBar"
                android:launchMode="singleInstance"
                android:taskAffinity=""
                android:configChanges="orientation|keyboardHidden|keyboard|navigation"/}
</pre>

<p>It's ok,but when I change<br/>
<b>android:theme="@android:style/Theme.Wallpaper.NoTitleBar"</b>
to
<b>android:theme="@android:style/Theme.Dialog"</b>
the screen did not turn on nor unlock, I am really confused....</p>

<p>Can you please tell me how to make the screen turn on and unlock when I use "@android:style/Theme.Dialog"?</p>

<p>Thanks</p>

<p>by the way,I have android 2.0 in my test device. </p>
