Merge "Clean up the legacy recent root task"
This commit is contained in:
committed by
Android (Google) Code Review
commit
6367ae118e
@@ -18,7 +18,6 @@ package com.android.server.wm;
|
||||
|
||||
import static android.app.ActivityTaskManager.INVALID_TASK_ID;
|
||||
import static android.app.WindowConfiguration.ACTIVITY_TYPE_HOME;
|
||||
import static android.app.WindowConfiguration.ACTIVITY_TYPE_RECENTS;
|
||||
import static android.app.WindowConfiguration.ACTIVITY_TYPE_UNDEFINED;
|
||||
import static android.app.WindowConfiguration.WINDOWING_MODE_FREEFORM;
|
||||
import static android.app.WindowConfiguration.WINDOWING_MODE_FULLSCREEN;
|
||||
@@ -111,9 +110,6 @@ final class TaskDisplayArea extends DisplayArea<WindowContainer> {
|
||||
private Task mRootHomeTask;
|
||||
private Task mRootPinnedTask;
|
||||
|
||||
// TODO(b/159029784): Remove when getStack() behavior is cleaned-up
|
||||
private Task mRootRecentsTask;
|
||||
|
||||
private final ArrayList<WindowContainer> mTmpAlwaysOnTopChildren = new ArrayList<>();
|
||||
private final ArrayList<WindowContainer> mTmpNormalChildren = new ArrayList<>();
|
||||
private final ArrayList<WindowContainer> mTmpHomeChildren = new ArrayList<>();
|
||||
@@ -222,8 +218,6 @@ final class TaskDisplayArea extends DisplayArea<WindowContainer> {
|
||||
Task getRootTask(int windowingMode, int activityType) {
|
||||
if (activityType == ACTIVITY_TYPE_HOME) {
|
||||
return mRootHomeTask;
|
||||
} else if (activityType == ACTIVITY_TYPE_RECENTS) {
|
||||
return mRootRecentsTask;
|
||||
}
|
||||
if (windowingMode == WINDOWING_MODE_PINNED) {
|
||||
return mRootPinnedTask;
|
||||
@@ -249,11 +243,6 @@ final class TaskDisplayArea extends DisplayArea<WindowContainer> {
|
||||
return mRootHomeTask;
|
||||
}
|
||||
|
||||
@Nullable
|
||||
Task getRootRecentsTask() {
|
||||
return mRootRecentsTask;
|
||||
}
|
||||
|
||||
Task getRootPinnedTask() {
|
||||
return mRootPinnedTask;
|
||||
}
|
||||
@@ -288,16 +277,6 @@ final class TaskDisplayArea extends DisplayArea<WindowContainer> {
|
||||
} else {
|
||||
mRootHomeTask = rootTask;
|
||||
}
|
||||
} else if (rootTask.isActivityTypeRecents()) {
|
||||
if (mRootRecentsTask != null) {
|
||||
if (!rootTask.isDescendantOf(mRootRecentsTask)) {
|
||||
throw new IllegalArgumentException("addRootTaskReferenceIfNeeded: root recents"
|
||||
+ " task=" + mRootRecentsTask + " already exist on display=" + this
|
||||
+ " rootTask=" + rootTask);
|
||||
}
|
||||
} else {
|
||||
mRootRecentsTask = rootTask;
|
||||
}
|
||||
}
|
||||
|
||||
if (!rootTask.isRootTask()) {
|
||||
@@ -317,8 +296,6 @@ final class TaskDisplayArea extends DisplayArea<WindowContainer> {
|
||||
void removeRootTaskReferenceIfNeeded(Task rootTask) {
|
||||
if (rootTask == mRootHomeTask) {
|
||||
mRootHomeTask = null;
|
||||
} else if (rootTask == mRootRecentsTask) {
|
||||
mRootRecentsTask = null;
|
||||
} else if (rootTask == mRootPinnedTask) {
|
||||
mRootPinnedTask = null;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user