summaryrefslogtreecommitdiffstats
path: root/services
diff options
context:
space:
mode:
Diffstat (limited to 'services')
-rwxr-xr-xservices/core/java/com/android/server/am/ActivityStack.java10
1 files changed, 5 insertions, 5 deletions
diff --git a/services/core/java/com/android/server/am/ActivityStack.java b/services/core/java/com/android/server/am/ActivityStack.java
index 6497cd7..7908da0 100755
--- a/services/core/java/com/android/server/am/ActivityStack.java
+++ b/services/core/java/com/android/server/am/ActivityStack.java
@@ -1525,14 +1525,14 @@ final class ActivityStack {
// Now the task above it has to return to the home task instead.
final int taskNdx = mTaskHistory.indexOf(prevTask) + 1;
mTaskHistory.get(taskNdx).setTaskToReturnTo(HOME_ACTIVITY_TYPE);
- } else if (!isOnHomeDisplay()) {
- return false;
- } else if (!isHomeStack()){
- if (DEBUG_STATES) Slog.d(TAG,
+ } else {
+ if (DEBUG_STATES && isOnHomeDisplay()) Slog.d(TAG,
"resumeTopActivityLocked: Launching home next");
+ // Only resume home if on home display
final int returnTaskType = prevTask == null || !prevTask.isOverHomeStack() ?
HOME_ACTIVITY_TYPE : prevTask.getTaskToReturnTo();
- return mStackSupervisor.resumeHomeStackTask(returnTaskType, prev, "prevFinished");
+ return isOnHomeDisplay() &&
+ mStackSupervisor.resumeHomeStackTask(returnTaskType, prev, "prevFinished");
}
}