summaryrefslogtreecommitdiffstats
path: root/services/java/com/android/server/am/ActivityStackSupervisor.java
diff options
context:
space:
mode:
Diffstat (limited to 'services/java/com/android/server/am/ActivityStackSupervisor.java')
-rw-r--r--services/java/com/android/server/am/ActivityStackSupervisor.java4
1 files changed, 4 insertions, 0 deletions
diff --git a/services/java/com/android/server/am/ActivityStackSupervisor.java b/services/java/com/android/server/am/ActivityStackSupervisor.java
index 8b946e4..7a6687e 100644
--- a/services/java/com/android/server/am/ActivityStackSupervisor.java
+++ b/services/java/com/android/server/am/ActivityStackSupervisor.java
@@ -72,6 +72,8 @@ import java.util.ArrayList;
import java.util.List;
public class ActivityStackSupervisor {
+ static final boolean DEBUG_STACK = ActivityManagerService.DEBUG_STACK;
+
static final boolean DEBUG = ActivityManagerService.DEBUG || false;
static final boolean DEBUG_ADD_REMOVE = DEBUG || false;
static final boolean DEBUG_APP = DEBUG || false;
@@ -237,9 +239,11 @@ public class ActivityStackSupervisor {
void removeTask(TaskRecord task) {
final ActivityStack stack = task.stack;
if (stack.removeTask(task) && !stack.isHomeStack()) {
+ if (DEBUG_STACK) Slog.i(TAG, "removeTask: removing stack " + stack);
mStacks.remove(stack);
final int stackId = stack.mStackId;
final int nextStackId = mService.mWindowManager.removeStack(stackId);
+ // TODO: Perhaps we need to let the ActivityManager determine the next focus...
if (mFocusedStack.mStackId == stackId) {
mFocusedStack = nextStackId == HOME_STACK_ID ? null : getStack(nextStackId);
}