Merge "Added featureId to DisplayAreaInfo" into rvc-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
1e6ef9321a
@@ -5277,12 +5277,13 @@ package android.widget {
|
||||
package android.window {
|
||||
|
||||
public final class DisplayAreaInfo implements android.os.Parcelable {
|
||||
ctor public DisplayAreaInfo(@NonNull android.window.WindowContainerToken, int);
|
||||
ctor public DisplayAreaInfo(@NonNull android.window.WindowContainerToken, int, int);
|
||||
method public int describeContents();
|
||||
method public void writeToParcel(@NonNull android.os.Parcel, int);
|
||||
field @NonNull public static final android.os.Parcelable.Creator<android.window.DisplayAreaInfo> CREATOR;
|
||||
field @NonNull public final android.content.res.Configuration configuration;
|
||||
field public final int displayId;
|
||||
field public final int featureId;
|
||||
field @NonNull public final android.window.WindowContainerToken token;
|
||||
}
|
||||
|
||||
|
||||
@@ -43,15 +43,19 @@ public final class DisplayAreaInfo implements Parcelable {
|
||||
*/
|
||||
public final int displayId;
|
||||
|
||||
public DisplayAreaInfo(@NonNull WindowContainerToken token, int displayId) {
|
||||
public final int featureId;
|
||||
|
||||
public DisplayAreaInfo(@NonNull WindowContainerToken token, int displayId, int featureId) {
|
||||
this.token = token;
|
||||
this.displayId = displayId;
|
||||
this.featureId = featureId;
|
||||
}
|
||||
|
||||
private DisplayAreaInfo(Parcel in) {
|
||||
token = WindowContainerToken.CREATOR.createFromParcel(in);
|
||||
configuration.readFromParcel(in);
|
||||
displayId = in.readInt();
|
||||
featureId = in.readInt();
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -59,6 +63,7 @@ public final class DisplayAreaInfo implements Parcelable {
|
||||
token.writeToParcel(dest, flags);
|
||||
configuration.writeToParcel(dest, flags);
|
||||
dest.writeInt(displayId);
|
||||
dest.writeInt(featureId);
|
||||
}
|
||||
|
||||
@NonNull
|
||||
|
||||
@@ -176,7 +176,7 @@ public class DisplayArea<T extends WindowContainer> extends WindowContainer<T> {
|
||||
|
||||
DisplayAreaInfo getDisplayAreaInfo() {
|
||||
DisplayAreaInfo info = new DisplayAreaInfo(mRemoteToken.toWindowContainerToken(),
|
||||
getDisplayContent().getDisplayId());
|
||||
getDisplayContent().getDisplayId(), mFeatureId);
|
||||
info.configuration.setTo(getConfiguration());
|
||||
return info;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user