| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
|
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
|
| 13 |
|
| 14 |
|
| 15 |
|
| 16 |
|
| 17 |
package android.window; |
| 18 |
|
| 19 |
import android.annotation.NonNull; |
| 20 |
import android.annotation.Nullable; |
| 21 |
import android.graphics.Rect; |
| 22 |
import android.os.Parcel; |
| 23 |
import android.os.Parcelable; |
| 24 |
import android.view.SurfaceControl; |
| 25 |
|
| 26 |
|
| 27 |
|
| 28 |
|
| 29 |
|
| 30 |
public final class StartingWindowRemovalInfo implements Parcelable { |
| 31 |
|
| 32 |
|
| 33 |
|
| 34 |
|
| 35 |
|
| 36 |
public int taskId; |
| 37 |
|
| 38 |
|
| 39 |
|
| 40 |
|
| 41 |
|
| 42 |
@Nullable |
| 43 |
public SurfaceControl windowAnimationLeash; |
| 44 |
|
| 45 |
|
| 46 |
|
| 47 |
|
| 48 |
|
| 49 |
@Nullable |
| 50 |
public Rect mainFrame; |
| 51 |
|
| 52 |
|
| 53 |
|
| 54 |
|
| 55 |
|
| 56 |
public boolean playRevealAnimation; |
| 57 |
|
| 58 |
|
| 59 |
|
| 60 |
|
| 61 |
|
| 62 |
public boolean deferRemoveForIme; |
| 63 |
|
| 64 |
|
| 65 |
|
| 66 |
|
| 67 |
|
| 68 |
public float roundedCornerRadius; |
| 69 |
|
| 70 |
public StartingWindowRemovalInfo() { |
| 71 |
|
| 72 |
} |
| 73 |
|
| 74 |
private StartingWindowRemovalInfo(@NonNull Parcel source) { |
| 75 |
readFromParcel(source); |
| 76 |
} |
| 77 |
|
| 78 |
@Override |
| 79 |
public int describeContents() { |
| 80 |
return 0; |
| 81 |
} |
| 82 |
|
| 83 |
void readFromParcel(@NonNull Parcel source) { |
| 84 |
taskId = source.readInt(); |
| 85 |
windowAnimationLeash = source.readTypedObject(SurfaceControl.CREATOR); |
| 86 |
mainFrame = source.readTypedObject(Rect.CREATOR); |
| 87 |
playRevealAnimation = source.readBoolean(); |
| 88 |
deferRemoveForIme = source.readBoolean(); |
| 89 |
roundedCornerRadius = source.readFloat(); |
| 90 |
} |
| 91 |
|
| 92 |
@Override |
| 93 |
public void writeToParcel(@NonNull Parcel dest, int flags) { |
| 94 |
dest.writeInt(taskId); |
| 95 |
dest.writeTypedObject(windowAnimationLeash, flags); |
| 96 |
dest.writeTypedObject(mainFrame, flags); |
| 97 |
dest.writeBoolean(playRevealAnimation); |
| 98 |
dest.writeBoolean(deferRemoveForIme); |
| 99 |
dest.writeFloat(roundedCornerRadius); |
| 100 |
} |
| 101 |
|
| 102 |
@Override |
| 103 |
public String toString() { |
| 104 |
return "StartingWindowRemovalInfo{taskId=" + taskId |
| 105 |
+ " frame=" + mainFrame |
| 106 |
+ " playRevealAnimation=" + playRevealAnimation |
| 107 |
+ " roundedCornerRadius=" + roundedCornerRadius |
| 108 |
+ " deferRemoveForIme=" + deferRemoveForIme + "}"; |
| 109 |
} |
| 110 |
|
| 111 |
public static final @android.annotation.NonNull Creator<StartingWindowRemovalInfo> CREATOR = |
| 112 |
new Creator<StartingWindowRemovalInfo>() { |
| 113 |
public StartingWindowRemovalInfo createFromParcel(@NonNull Parcel source) { |
| 114 |
return new StartingWindowRemovalInfo(source); |
| 115 |
} |
| 116 |
public StartingWindowRemovalInfo[] newArray(int size) { |
| 117 |
return new StartingWindowRemovalInfo[size]; |
| 118 |
} |
| 119 |
}; |
| 120 |
} |