Merge "Add null check for recents when tapping on Taskbar icons" into tm-qpr-dev

This commit is contained in:
Vinit Nayak
2023-03-03 21:33:52 +00:00
committed by Android (Google) Code Review

View File

@@ -877,7 +877,11 @@ public class TaskbarActivityContext extends BaseTaskbarContext {
* as if the user tapped on it (preserving the split pair). Otherwise, launch it normally
* (potentially breaking a split pair).
*/
private void launchFromTaskbarPreservingSplitIfVisible(RecentsView recents, ItemInfo info) {
private void launchFromTaskbarPreservingSplitIfVisible(@Nullable RecentsView recents,
ItemInfo info) {
if (recents == null) {
return;
}
ComponentKey componentToBeLaunched = new ComponentKey(info.getTargetComponent(), info.user);
recents.getSplitSelectController().findLastActiveTaskAndRunCallback(
componentToBeLaunched,