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

Commit 56c502db authored by Yining Liu's avatar Yining Liu
Browse files

Use throttle flag for group hun animation fix

Use the avalanche throttle hun flag for the group hun animation fix.
Because this bugfix improves the animation quality when the throttle
hun is enabled.

Fix: 357121423
Flag: com.android.systemui.notification_avalanche_throttle_hun
Test: HeadsUpCoordinatorTest
Change-Id: I0a615b1720c72f009cbee79efbcaf171a1ed6c36
parent e3a65aec
Loading
Loading
Loading
Loading
+0 −11
Original line number Diff line number Diff line
@@ -226,17 +226,6 @@ flag {
    bug: "294830092"
}

flag {
    name: "notification_group_hun_removal_animation_fix"
    namespace: "systemui"
    description: "Fix the lack of hun removal animation for group notifications"
        "(not GROUP_ALERT_SUMMARY)"
    bug: "343475993"
    metadata {
        purpose: PURPOSE_BUGFIX
    }
}

flag {
    name: "scene_container"
    namespace: "systemui"
+6 −3
Original line number Diff line number Diff line
@@ -20,10 +20,13 @@ import com.android.systemui.Flags
import com.android.systemui.flags.FlagToken
import com.android.systemui.flags.RefactorFlagUtils

/** Helper for com.android.systemui.Flags.FLAG_NOTIFICATION_GROUP_HUN_REMOVAL_ANIMATION_FIX */
/**
 * Helper for com.android.systemui.Flags.FLAG_NOTIFICATION_GROUP_HUN_REMOVAL_ANIMATION_FIX, which
 * now uses FLAG_NOTIFICATION_AVALANCHE_THROTTLE_HUN
 */
@Suppress("NOTHING_TO_INLINE")
object GroupHunAnimationFix {
    const val FLAG_NAME = Flags.FLAG_NOTIFICATION_GROUP_HUN_REMOVAL_ANIMATION_FIX
    const val FLAG_NAME = Flags.FLAG_NOTIFICATION_AVALANCHE_THROTTLE_HUN

    /** A token used for dependency declaration */
    val token: FlagToken
@@ -32,7 +35,7 @@ object GroupHunAnimationFix {
    /** Return whether the fix is enabled */
    @JvmStatic
    inline val isEnabled
        get() = Flags.notificationGroupHunRemovalAnimationFix()
        get() = Flags.notificationAvalancheThrottleHun()

    /**
     * Called to ensure code is only run when the flag is enabled. This protects users from the