Loading
Removed unnecessary initial value when collecting StateFlow
Shortcut customization dialogs were janky and animating using an unexpected transition when launched. Investigation showed that this was due to a faulty state collection - when collecting shortcutUiCustomizationState with lifecycle, we added an intial value `Inactive`. This causes the initial root composable to first be composed with state Inactive, showing the UI for Inactive state(empty UI but with Scrim) and then recompose with a new correct state, discarding the empty UI and showing the new correct UI(hence the odd animation when launching). Basically, we were showing two different UIs(a wrong empty UI, followed by the correct UI) and this caused unexpected behaviors in window enter animations. Flag: com.android.systemui.keyboard_shortcut_helper_shortcut_customizer Test: Manual - ensure enter animation for customization dialog is consistent with systemUIDialog animations across the board. Fix: 381060204 Change-Id: Ief4a2a30d6bd346f0ba5ff7ab96be204e11f2ae9