Loading
[31/N] Desks: Consolidate desk activation utils
This change unifies some duplicated activation logic that existed in both prepareMoveTaskToDeskAndActive() and addDeskActivationChanges(). prepareMoveTaskToDeskAndActive() was essentially doing the same work that addDeskActivationChanges() did, plus calling addMoveToDeskTaskChanges(). With this change, the prepare() function now internally uses addDeskActivationChanges(), and is renamed to addDeskActivationWithMovingTaskChanges() to follow the existing addXChanges() pattern. It also removes bringDesktopAppsToFrontBeforeShowingNewTask(), since it's just an overloaded version of bringDesktopAppsToFront that shouldn't be needed in kotlin. This is a pure refactor, so no behavior changes are expected. Flag: com.android.window.flags.enable_multiple_desktops_backend Bug: 362720497 Test: atest WMShellUnitTests Change-Id: Ife6b80c23f03b0f71a4b2f37c5f231df068e1035