Merge "Hide running time information for "Android System" entry" into tm-dev am: fc6cb73d29

Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/18062824

Change-Id: Iaefe2c50673077f1aac0e77f03e27451911a2885
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
TreeHugger Robot
2022-04-29 16:39:55 +00:00
committed by Automerger Merge Worker

View File

@@ -424,6 +424,9 @@ public class BatteryAppListPreferenceController extends AbstractPreferenceContro
@VisibleForTesting @VisibleForTesting
void setUsageSummary(Preference preference, BatteryEntry entry) { void setUsageSummary(Preference preference, BatteryEntry entry) {
if (entry.getUid() == Process.SYSTEM_UID) {
return;
}
// Only show summary when usage time is longer than one minute // Only show summary when usage time is longer than one minute
final long usageTimeMs = entry.getTimeInForegroundMs(); final long usageTimeMs = entry.getTimeInForegroundMs();
if (shouldShowSummary(entry) && usageTimeMs >= DateUtils.MINUTE_IN_MILLIS) { if (shouldShowSummary(entry) && usageTimeMs >= DateUtils.MINUTE_IN_MILLIS) {