Merge "Don't change bucketing reason if app is already in better bucket." into tm-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
7950f77ee3
@@ -328,11 +328,13 @@ public class AppIdleHistory {
|
||||
appUsageHistory.lastUsedScreenTime = getScreenOnTime(nowElapsedRealtimeMs);
|
||||
}
|
||||
|
||||
if (appUsageHistory.currentBucket > newBucket) {
|
||||
appUsageHistory.currentBucket = newBucket;
|
||||
logAppStandbyBucketChanged(packageName, userId, newBucket, bucketingReason);
|
||||
if (appUsageHistory.currentBucket >= newBucket) {
|
||||
if (appUsageHistory.currentBucket > newBucket) {
|
||||
appUsageHistory.currentBucket = newBucket;
|
||||
logAppStandbyBucketChanged(packageName, userId, newBucket, bucketingReason);
|
||||
}
|
||||
appUsageHistory.bucketingReason = bucketingReason;
|
||||
}
|
||||
appUsageHistory.bucketingReason = bucketingReason;
|
||||
|
||||
return appUsageHistory;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user