Merge "Capture layer and children when calling takeSurfaceControlScreenshot" into sc-dev

This commit is contained in:
Chavi Weingarten
2021-05-05 19:43:52 +00:00
committed by Android (Google) Code Review

View File

@@ -220,7 +220,9 @@ public final class UiAutomationConnection extends IUiAutomationConnection.Stub {
final long identity = Binder.clearCallingIdentity();
try {
captureBuffer = SurfaceControl.captureLayers(
new SurfaceControl.LayerCaptureArgs.Builder(surfaceControl).build());
new SurfaceControl.LayerCaptureArgs.Builder(surfaceControl)
.setChildrenOnly(false)
.build());
} finally {
Binder.restoreCallingIdentity(identity);
}