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

Commit 3a7b2c16 authored by Shan Huang's avatar Shan Huang Committed by Automerger Merge Worker
Browse files

Merge "Ignore the charging ripple flag." into sc-v2-dev am: 8833af16

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/16470199

Change-Id: Ie0ecb98e50f56daa784316fd1ee5b72d8a02426c
parents 5be2e5c2 8833af16
Loading
Loading
Loading
Loading
+3 −4
Original line number Diff line number Diff line
@@ -93,9 +93,8 @@ class WiredChargingRippleController @Inject constructor(
                nowPluggedIn: Boolean,
                charging: Boolean
            ) {
                // Suppresses the ripple when it's disabled, or when the state change comes
                // from wireless charging.
                if (!rippleEnabled || batteryController.isPluggedInWireless) {
                // Suppresses the ripple when the state change comes from wireless charging.
                if (batteryController.isPluggedInWireless) {
                    return
                }
                val wasPluggedIn = pluggedIn
@@ -145,7 +144,7 @@ class WiredChargingRippleController @Inject constructor(
    }

    fun startRipple() {
        if (!rippleEnabled || rippleView.rippleInProgress || rippleView.parent != null) {
        if (rippleView.rippleInProgress || rippleView.parent != null) {
            // Skip if ripple is still playing, or not playing but already added the parent
            // (which might happen just before the animation starts or right after
            // the animation ends.)