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

Commit 98f182f7 authored by Jim Miller's avatar Jim Miller Committed by Android (Google) Code Review
Browse files

Merge "Fix 2447470: always update the battery status when it's below the threshold."

parents 6019c9d9 cdb70af7
Loading
Loading
Loading
Loading
+2 −8
Original line number Diff line number Diff line
@@ -385,14 +385,8 @@ public class KeyguardUpdateMonitor {
        }

        if (!pluggedIn) {
            // not plugged in and going below threshold
            if (batteryLevel < LOW_BATTERY_THRESHOLD
                    && mBatteryLevel >= LOW_BATTERY_THRESHOLD) {
                return true;
            }
            // not plugged in and going above threshold (sounds impossible, but, meh...)
            if (mBatteryLevel < LOW_BATTERY_THRESHOLD
                    && batteryLevel >= LOW_BATTERY_THRESHOLD) {
            // not plugged in and below threshold
            if (batteryLevel < LOW_BATTERY_THRESHOLD && batteryLevel != mBatteryLevel) {
                return true;
            }
        }