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

Commit d425eee2 authored by Jorge Gil's avatar Jorge Gil
Browse files

Clear mPreferredTopFocusableRootTask when root becomes empty

In multi-desks, the focused root task may have its only child desktop
window reparented out into the back of another container, leaving the
empty root incorrectly set as focused. Clear the TDA preferred focusable
root task when this happens so that getFocusedRootTask() doesn't select
the empty task as the focused one.

Flag: com.android.window.flags.enable_multiple_desktops_backend
Bug: 420858253
Test: minimize the last task in a desk, then check dumpsys:
 1) mPreferredTopFocusableRootTask is the DesktopWallpaperActivity task
 2) Desk remains "active" in DesktopRepository and DesksOrganizer
Test: back-nav the last task in a desk (Gmail log in screen to force a
move to back instead a of a close) - verify the same as above

Change-Id: I0e7fb75a62bb8f8d1444e88e95904ba7224cc354
parent 325d92db
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