Android WakeLock and KeyGuard
<p>I'm just wondering if I do this correctly; I'm programming a notification app which can display a notification when the phone is sleeping</p>

<ol>
<li>Disable keyguard lock</li>
<li>Aquire a wake lock</li>
<li>show notification </li>
<li>Set alarm for timeout and reenabling keyguard and release wakelock is the user dont touches the screen.
4.1 User touches the screen, and I disable the timer. Do nothing more. Done and done
4.2 User dont touch the screen, so reenable keyguard and release wakelock. Phone sleeps again</li>
</ol>

<p>Basically I'm wondering about point 4.1 the most. cancel the pendingintent for the alarm, and do nothing more? or should the keyguard and wakelock that are set be dealt with in some way?</p>
