Remove unnecessary converting us to ms in BatteryInfo
The class "Estimate" has the menber estimateMillis and the unit of batteryUsageStats.getBatteryTimeRemainingMs() is millisecond, so converting from us to ms is unnecessary. Bug: 187379252 Test: make RunSettingsRoboTests Change-Id: Iefbd8751608eb749367cf08a4a9b184b948a6d33
This commit is contained in:
@@ -204,7 +204,7 @@ public class BatteryInfo {
|
||||
final long prediction = discharging
|
||||
? stats.computeBatteryTimeRemaining(elapsedRealtimeUs) : 0;
|
||||
final Estimate estimate = new Estimate(
|
||||
PowerUtil.convertUsToMs(prediction),
|
||||
prediction,
|
||||
false, /* isBasedOnUsage */
|
||||
EstimateKt.AVERAGE_TIME_TO_DISCHARGE_UNKNOWN);
|
||||
BatteryUtils.logRuntime(LOG_TAG, "time for regular BatteryInfo", startTime);
|
||||
|
Reference in New Issue
Block a user