Skip to content

Commit baa2812

Browse files
author
Jim Miller
committed
Fix 5386408: Fix battery state information propagation in Lock Screen
This fixes a bug where Lock Screen would sometimes inappropriately show "charged" if it took a while for Lock Screen to get an update on the battery state. It now starts with the state set to BATTERY_STATUS_UNKNOWN so we properly update listeners when we finally get battery information in handleBatteryUpdate(). Change-Id: I71018a233f38b2f897ff2e6592d7e310550fa016
1 parent 338140f commit baa2812

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

policy/src/com/android/internal/policy/impl/KeyguardUpdateMonitor.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -218,7 +218,7 @@ public void onChange(boolean selfChange) {
218218

219219
// take a guess to start
220220
mSimState = IccCard.State.READY;
221-
mBatteryStatus = BATTERY_STATUS_FULL;
221+
mBatteryStatus = BATTERY_STATUS_UNKNOWN;
222222
mBatteryLevel = 100;
223223

224224
mTelephonyPlmn = getDefaultPlmn();

0 commit comments

Comments
 (0)