Merge "Fix ambient display time unit error" into pi-dev

This commit is contained in:
Mike Ma
2018-04-06 19:32:20 +00:00
committed by Android (Google) Code Review

View File

@@ -657,7 +657,7 @@ public class BatteryStatsHelper {
* {@link #removeHiddenBatterySippers(List)}.
*/
private void addAmbientDisplayUsage() {
long ambientDisplayMs = mStats.getScreenDozeTime(mRawRealtimeUs, mStatsType);
long ambientDisplayMs = mStats.getScreenDozeTime(mRawRealtimeUs, mStatsType) / 1000;
double power = mPowerProfile.getAveragePower(PowerProfile.POWER_AMBIENT_DISPLAY)
* ambientDisplayMs / (60 * 60 * 1000);
if (power > 0) {