Merge "Fix letterbox issue when auto-enter-pip from landscape" into sc-dev am: 5a59072018
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15264487 Change-Id: Ibe24016daf3ee670b498a24eb80ae3dc2f1df0b3
This commit is contained in:
@@ -28,11 +28,13 @@ import android.content.LocusId;
|
||||
import android.content.pm.ActivityInfo;
|
||||
import android.content.res.Configuration;
|
||||
import android.graphics.Point;
|
||||
import android.graphics.Rect;
|
||||
import android.os.Build;
|
||||
import android.os.IBinder;
|
||||
import android.os.Parcel;
|
||||
import android.os.RemoteException;
|
||||
import android.util.Log;
|
||||
import android.view.DisplayCutout;
|
||||
import android.window.TaskSnapshot;
|
||||
import android.window.WindowContainerToken;
|
||||
|
||||
@@ -173,6 +175,15 @@ public class TaskInfo {
|
||||
@Nullable
|
||||
public PictureInPictureParams pictureInPictureParams;
|
||||
|
||||
/**
|
||||
* The {@link Rect} copied from {@link DisplayCutout#getSafeInsets()} if the cutout is not of
|
||||
* (LAYOUT_IN_DISPLAY_CUTOUT_MODE_SHORT_EDGES, LAYOUT_IN_DISPLAY_CUTOUT_MODE_ALWAYS),
|
||||
* {@code null} otherwise.
|
||||
* @hide
|
||||
*/
|
||||
@Nullable
|
||||
public Rect displayCutoutInsets;
|
||||
|
||||
/**
|
||||
* The activity type of the top activity in this task.
|
||||
* @hide
|
||||
@@ -332,6 +343,7 @@ public class TaskInfo {
|
||||
&& supportsMultiWindow == that.supportsMultiWindow
|
||||
&& Objects.equals(positionInParent, that.positionInParent)
|
||||
&& Objects.equals(pictureInPictureParams, that.pictureInPictureParams)
|
||||
&& Objects.equals(displayCutoutInsets, that.displayCutoutInsets)
|
||||
&& getWindowingMode() == that.getWindowingMode()
|
||||
&& Objects.equals(taskDescription, that.taskDescription)
|
||||
&& isFocused == that.isFocused
|
||||
@@ -382,6 +394,7 @@ public class TaskInfo {
|
||||
token = WindowContainerToken.CREATOR.createFromParcel(source);
|
||||
topActivityType = source.readInt();
|
||||
pictureInPictureParams = source.readTypedObject(PictureInPictureParams.CREATOR);
|
||||
displayCutoutInsets = source.readTypedObject(Rect.CREATOR);
|
||||
topActivityInfo = source.readTypedObject(ActivityInfo.CREATOR);
|
||||
isResizeable = source.readBoolean();
|
||||
source.readBinderList(launchCookies);
|
||||
@@ -419,6 +432,7 @@ public class TaskInfo {
|
||||
token.writeToParcel(dest, flags);
|
||||
dest.writeInt(topActivityType);
|
||||
dest.writeTypedObject(pictureInPictureParams, flags);
|
||||
dest.writeTypedObject(displayCutoutInsets, flags);
|
||||
dest.writeTypedObject(topActivityInfo, flags);
|
||||
dest.writeBoolean(isResizeable);
|
||||
dest.writeBinderList(launchCookies);
|
||||
@@ -447,6 +461,7 @@ public class TaskInfo {
|
||||
+ " token=" + token
|
||||
+ " topActivityType=" + topActivityType
|
||||
+ " pictureInPictureParams=" + pictureInPictureParams
|
||||
+ " displayCutoutSafeInsets=" + displayCutoutInsets
|
||||
+ " topActivityInfo=" + topActivityInfo
|
||||
+ " launchCookies=" + launchCookies
|
||||
+ " positionInParent=" + positionInParent
|
||||
|
||||
Reference in New Issue
Block a user