Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e61447b6 authored by Ikram Gabiyev's avatar Ikram Gabiyev
Browse files

[PiP] Set a task id to the pinned task on build

When a task contains multiple activities
and the top activity enters PiP, we reparent it
to a new pinned task.

Not calling setParent as we use the task builder
leads to validateRootTask() not being called, which in turn
doesn't assign a proper default task id to our new pinned task.
So instead we should set a task id ourselves.

The CL that introduced this regression ag/33762396 was targeting
a separate valid issue where validateRootTask would reparent this
task to a DeskRoot in DW mode; so there we stopped assigning a default
parent to the task upon creation.

Bug: 422952179
Flag: com.android.wm.shell.enable_pip2
Test: enter multi-activity PiP, then directly enter another
  multi-activity PiP to replace the first one
Test: "adb shell dumpsys activity activities top" after entering
  multi-activity PiP and check that taskId != 0
Change-Id: I7cbb7c942358d3b2af22432f19745a59e82c0696
parent fcc1cbfe
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment