summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Craig Mautner <cmautner@google.com> 2014-11-20 15:06:40 -0800
committer Craig Mautner <cmautner@google.com> 2014-11-20 15:06:40 -0800
commitf49b0a45aece9bad42d81a09eeceaf1b5b6c06df (patch)
tree85fab608dc69b53df9ecf83b63586583e9e0c5b5
parentc70a4ccf45f669c07345cd438d68747d0558fd49 (diff)
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
-rwxr-xr-xservices/core/java/com/android/server/am/ActivityStack.java4
1 files changed, 4 insertions, 0 deletions
diff --git a/services/core/java/com/android/server/am/ActivityStack.java b/services/core/java/com/android/server/am/ActivityStack.java
index 3a1fafe2bbc3..eee5340c6129 100755
--- a/services/core/java/com/android/server/am/ActivityStack.java
+++ b/services/core/java/com/android/server/am/ActivityStack.java
@@ -700,6 +700,10 @@ final class ActivityStack {
activities.get(activityNdx).setSleeping(false);
}
}
+ if (mPausingActivity != null) {
+ Slog.d(TAG, "awakeFromSleepingLocked: previously pausing activity didn't pause");
+ activityPausedLocked(mPausingActivity.appToken, true);
+ }
}
/**