Merge "Reset crop after finished transition" into tm-dev am: 02853a7ae4
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/17537787 Change-Id: I00d58372a5d82aef1272646cf1ba54cb17fa526d Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -426,6 +426,21 @@ class Transition extends Binder implements BLASTSyncEngine.TransactionReadyListe
|
|||||||
t.setLayer(targetLeash, target.getLastLayer());
|
t.setLayer(targetLeash, target.getLastLayer());
|
||||||
target.getRelativePosition(tmpPos);
|
target.getRelativePosition(tmpPos);
|
||||||
t.setPosition(targetLeash, tmpPos.x, tmpPos.y);
|
t.setPosition(targetLeash, tmpPos.x, tmpPos.y);
|
||||||
|
final Rect clipRect;
|
||||||
|
// No need to clip the display in case seeing the clipped content when during the
|
||||||
|
// display rotation.
|
||||||
|
if (target.asDisplayContent() != null) {
|
||||||
|
clipRect = null;
|
||||||
|
} else if (target.asActivityRecord() != null) {
|
||||||
|
// Always use parent bounds of activity because letterbox area (e.g. fixed
|
||||||
|
// aspect ratio or size compat mode) should be included.
|
||||||
|
clipRect = target.getParent().getRequestedOverrideBounds();
|
||||||
|
clipRect.offset(-tmpPos.x, -tmpPos.y);
|
||||||
|
} else {
|
||||||
|
clipRect = target.getRequestedOverrideBounds();
|
||||||
|
clipRect.offset(-tmpPos.x, -tmpPos.y);
|
||||||
|
}
|
||||||
|
t.setCrop(targetLeash, clipRect);
|
||||||
t.setCornerRadius(targetLeash, 0);
|
t.setCornerRadius(targetLeash, 0);
|
||||||
t.setShadowRadius(targetLeash, 0);
|
t.setShadowRadius(targetLeash, 0);
|
||||||
t.setMatrix(targetLeash, 1, 0, 0, 1);
|
t.setMatrix(targetLeash, 1, 0, 0, 1);
|
||||||
|
|||||||
Reference in New Issue
Block a user