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

Commit 03d7d474 authored by Ikram Gabiyev's avatar Ikram Gabiyev
Browse files

[PiP2] Do not pip when candidate transient hides

In PiP2, we are setting/resetting supportsEnterPipOnTaskSwitch
downstream as we startPausing, right before we decide to auto-enter or
not.

This means in cases like quickswitch, where there is a follow-up
transition, we can't really rely on ActivityOptions$mTransientLaunch
to decide whether to set the flag or not (only the first transition
transient launches home, the follow-up quickswitch transition doesn't
transient launch the next toFrontActivity).

Thus, a more reliable way of checking whether we are in quickswitch, for
instance, is whether the pipCandidate's root task is transient hiding,
as the first recents transition that is still playing and is waiting for
the second one to merge into it will also be checked for transient
hides.

Bug: 406503807
Flag: com.android.wm.shell.enable_pip2
Test: manually repro the steps in the bug

Change-Id: If35e9ed86c3d865300d0635acdb56b42291def0b
parent cf320c95
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