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

Commit 550972cb authored by android-build-team Robot's avatar android-build-team Robot Committed by Android (Google) Code Review
Browse files

Merge "Reset short term model on user switch." into pi-dev

parents 33cb3b72 c1352254
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -316,7 +316,7 @@ class AutomaticBrightnessController {
        return true;
    }

    private void resetShortTermModel() {
    public void resetShortTermModel() {
        mBrightnessMapper.clearUserDataPoints();
        mShortTermModelValid = true;
        mShortTermModelAnchor = -1;
+3 −0
Original line number Diff line number Diff line
@@ -1452,6 +1452,9 @@ final class DisplayPowerController implements AutomaticBrightnessController.Call
        if (userSwitch) {
            // Don't treat user switches as user initiated change.
            mCurrentScreenBrightnessSetting = mPendingScreenBrightnessSetting;
            if (mAutomaticBrightnessController != null) {
                mAutomaticBrightnessController.resetShortTermModel();
            }
        }
        mPendingAutoBrightnessAdjustment = getAutoBrightnessAdjustmentSetting();
        // We don't bother with a pending variable for VR screen brightness since we just