Remove InputConsumer, replacing with InputQueue.
Change-Id: Ib06907278457aaee842b123adc072840ca3602d8
diff --git a/core/java/com/android/internal/os/BatteryStatsImpl.java b/core/java/com/android/internal/os/BatteryStatsImpl.java
index f8ab04c..642c313 100644
--- a/core/java/com/android/internal/os/BatteryStatsImpl.java
+++ b/core/java/com/android/internal/os/BatteryStatsImpl.java
@@ -3892,6 +3892,17 @@
mHistoryBaseTime = rec.time;
}
}
+
+ long oldnow = SystemClock.elapsedRealtime() - (5*60*100);
+ if (oldnow > 0) {
+ // If the system process has restarted, but not the entire
+ // system, then the mHistoryBaseTime already accounts for
+ // much of the elapsed time. We thus want to adjust it back,
+ // to avoid large gaps in the data. We determine we are
+ // in this case by arbitrarily saying it is so if at this
+ // point in boot the elapsed time is already more than 5 seconds.
+ mHistoryBaseTime -= oldnow;
+ }
}
void writeHistory(Parcel out) {