diff options
| author | 2023-03-11 07:07:30 +0000 | |
|---|---|---|
| committer | 2023-03-11 07:07:30 +0000 | |
| commit | 05905d067764243b7ebbad8092f1335eabdc28cc (patch) | |
| tree | 251ba48866369028574b97142ee84ee185e5bd19 | |
| parent | 72d2288d618db55e7a14d7219a3f86694db3d0ad (diff) | |
| parent | 9080ceaaf9a96c2aff9d5a248f2481a9188b0691 (diff) | |
Merge "Work around for NPE with shell transition" into tm-qpr-dev am: 6911cccd49 am: 9080ceaaf9
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/21965862
Change-Id: I47e50052d0b1b29bf373563154828537616470af
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
| -rw-r--r-- | libs/WindowManager/Shell/src/com/android/wm/shell/pip/PipTransition.java | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/libs/WindowManager/Shell/src/com/android/wm/shell/pip/PipTransition.java b/libs/WindowManager/Shell/src/com/android/wm/shell/pip/PipTransition.java index 2848f3444e21..87cf6559a0f0 100644 --- a/libs/WindowManager/Shell/src/com/android/wm/shell/pip/PipTransition.java +++ b/libs/WindowManager/Shell/src/com/android/wm/shell/pip/PipTransition.java @@ -797,8 +797,15 @@ public class PipTransition extends PipTransitionController { if (sourceHintRect == null) { // We use content overlay when there is no source rect hint to enter PiP use bounds // animation. + // TODO(b/272819817): cleanup the null-check and extra logging. + final boolean hasTopActivityInfo = taskInfo.topActivityInfo != null; + if (!hasTopActivityInfo) { + ProtoLog.w(ShellProtoLogGroup.WM_SHELL_TRANSITIONS, + "%s: TaskInfo.topActivityInfo is null", TAG); + } if (SystemProperties.getBoolean( - "persist.wm.debug.enable_pip_app_icon_overlay", true)) { + "persist.wm.debug.enable_pip_app_icon_overlay", true) + && hasTopActivityInfo) { animator.setAppIconContentOverlay( mContext, currentBounds, taskInfo.topActivityInfo); } else { |