Merge "Make animation leashes effect layers" into rvc-dev am: 215bb80b3f am: 379d06e8f3

Change-Id: I64a278a594ee1bb42e065d88ed12263a447608e8
This commit is contained in:
Vishnu Nair
2020-03-19 21:13:58 +00:00
committed by Automerger Merge Worker

View File

@@ -379,7 +379,8 @@ class SurfaceAnimator {
if (DEBUG_ANIM) Slog.i(TAG, "Reparenting to leash"); if (DEBUG_ANIM) Slog.i(TAG, "Reparenting to leash");
final SurfaceControl.Builder builder = animatable.makeAnimationLeash() final SurfaceControl.Builder builder = animatable.makeAnimationLeash()
.setParent(animatable.getAnimationLeashParent()) .setParent(animatable.getAnimationLeashParent())
.setName(surface + " - animation-leash"); .setName(surface + " - animation-leash")
.setColorLayer();
final SurfaceControl leash = builder.build(); final SurfaceControl leash = builder.build();
if (!hidden) { if (!hidden) {
// TODO(b/151665759) Defer reparent calls // TODO(b/151665759) Defer reparent calls
@@ -390,6 +391,7 @@ class SurfaceAnimator {
// seamless rotation. // seamless rotation.
transactionFactory.get().unsetColor(leash).show(leash).apply(); transactionFactory.get().unsetColor(leash).show(leash).apply();
} }
t.unsetColor(leash);
t.setWindowCrop(leash, width, height); t.setWindowCrop(leash, width, height);
t.setPosition(leash, x, y); t.setPosition(leash, x, y);
t.show(leash); t.show(leash);