Merge "Add information to Task model for desktop entry" into tm-qpr-dev

This commit is contained in:
TreeHugger Robot
2022-10-12 21:10:12 +00:00
committed by Android (Google) Code Review

View File

@@ -27,6 +27,8 @@ import android.app.ActivityManager.TaskDescription;
import android.app.TaskInfo; import android.app.TaskInfo;
import android.content.ComponentName; import android.content.ComponentName;
import android.content.Intent; import android.content.Intent;
import android.graphics.Point;
import android.graphics.Rect;
import android.graphics.drawable.Drawable; import android.graphics.drawable.Drawable;
import android.os.Parcel; import android.os.Parcel;
import android.os.Parcelable; import android.os.Parcelable;
@@ -233,17 +235,14 @@ public class Task {
@ViewDebug.ExportedProperty(category="recents") @ViewDebug.ExportedProperty(category="recents")
public boolean isLocked; public boolean isLocked;
public Point positionInParent;
public Rect appBounds;
// Last snapshot data, only used for recent tasks // Last snapshot data, only used for recent tasks
public ActivityManager.RecentTaskInfo.PersistedTaskSnapshotData lastSnapshotData = public ActivityManager.RecentTaskInfo.PersistedTaskSnapshotData lastSnapshotData =
new ActivityManager.RecentTaskInfo.PersistedTaskSnapshotData(); new ActivityManager.RecentTaskInfo.PersistedTaskSnapshotData();
/**
* Indicates that this task for the desktop tile in recents.
*
* Used when desktop mode feature is enabled.
*/
public boolean desktopTile;
public Task() { public Task() {
// Do nothing // Do nothing
} }
@@ -274,7 +273,8 @@ public class Task {
this(other.key, other.colorPrimary, other.colorBackground, other.isDockable, this(other.key, other.colorPrimary, other.colorBackground, other.isDockable,
other.isLocked, other.taskDescription, other.topActivity); other.isLocked, other.taskDescription, other.topActivity);
lastSnapshotData.set(other.lastSnapshotData); lastSnapshotData.set(other.lastSnapshotData);
desktopTile = other.desktopTile; positionInParent = other.positionInParent;
appBounds = other.appBounds;
} }
/** /**