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

Commit 4d269ba3 authored by Prashant Malani's avatar Prashant Malani Committed by Android Git Automerger
Browse files

am fb26a2c8: Merge "Don\'t animate screen brightness if there is a pending off...

am fb26a2c8: Merge "Don\'t animate screen brightness if there is a pending off transition" into lmp-sprout-dev

* commit 'fb26a2c8':
  Don't animate screen brightness if there is a pending off transition
parents 2a46722f fb26a2c8
Loading
Loading
Loading
Loading
+7 −5
Original line number Diff line number Diff line
@@ -669,12 +669,14 @@ final class DisplayPowerController implements AutomaticBrightnessController.Call

        // Animate the screen brightness when the screen is on or dozing.
        // Skip the animation when the screen is off or suspended.
        if (!mPendingScreenOff) {
            if (state == Display.STATE_ON || state == Display.STATE_DOZE) {
                animateScreenBrightness(brightness,
                        slowChange ? BRIGHTNESS_RAMP_RATE_SLOW : BRIGHTNESS_RAMP_RATE_FAST);
            } else {
                animateScreenBrightness(brightness, 0);
            }
        }

        // Determine whether the display is ready for use in the newly requested state.
        // Note that we do not wait for the brightness ramp animation to complete before