Add RootTaskDisplayAreaOrganizer.setPosition().

Bug: 191271445
Test: Send a command to change the cluster display size and check if it effects.
Change-Id: I84b0403d3a1ec15066cf16e37ca183abf897d080
This commit is contained in:
Yuncheol Heo
2021-06-24 14:30:32 -07:00
parent 532bb317c1
commit 24d18b6f18

View File

@@ -97,6 +97,14 @@ public class RootTaskDisplayAreaOrganizer extends DisplayAreaOrganizer {
b.setParent(sc);
}
public void setPosition(@NonNull SurfaceControl.Transaction tx, int displayId, int x, int y) {
final SurfaceControl sc = mLeashes.get(displayId);
if (sc == null) {
throw new IllegalArgumentException("can't find display" + displayId);
}
tx.setPosition(sc, x, y);
}
@Override
public void onDisplayAreaAppeared(@NonNull DisplayAreaInfo displayAreaInfo,
@NonNull SurfaceControl leash) {