[87/n] Handle Letterbox Surface Lifecycle in SplitScreen
Before this code, Changes for a no leaf Task were skipped at the TransitionObserver level to avoid the creation of letterbox surfaces using, as parent surface, the surface of Tasks without any activity. Now leaf tasks, the only allowed to provide the parent surface for the creation of the letterbox surfaces, are referenced in the LetterboxTaskInfoRepository and cannot be completely ignored. In case of split screen, for instance, the id of the Task received in the Change cannot be used directly but it will be used to identify the specific leaf Task from its parent using the logic in TaskIdResolver. After this change the requirement to not create letterbox surfaces for not leaf task will be accomplished because a LetterboxLifecycleEvent will be only created for those. LetterboxLifecycleEvent for not leaf tasks will be null and so skipped in DelegateLetterboxTransitionObserver. Flag: com.android.window.flags.app_compat_refactoring_fix_multiwindow_task_hierarchy Bug: 421103832 Test: atest WMShellUnitTests:DelegateLetterboxTransitionObserverTest Test: atest WMShellUnitTests:TaskInfoLetterboxLifecycleEventFactoryTest Test: atest WMShellUnitTests:MixedLetterboxControllerTest Test: atest WMShellUnitTests:LetterboxTaskListenerAdapterTest Change-Id: I522a2261c26468bb70535025d4edfd4a8aae3d17
Loading
Please register or sign in to comment