Treat screen-on while pausing as pause timeout.

If an activity is started pausing when the screen turns off and
hasn't completed pausing by the time the screen turns back on then
we will end up showing the activity below it when the pause times
out.

In particular pausing the secure camera exposes the activity on
the top of the stack if you turn the screen off and back on
immediately.

Immediately forcing the existing pause to complete when the screen
comes back on allows the keyguard to obscure anything that might
otherwise be shown.

Fixes bug 17713150.

Change-Id: Ibe275991aa325a7d326bf2a24511aeb4dcbb7e1b
1 file changed