summaryrefslogtreecommitdiff
path: root/core/java/android/util/SparseArrayMap.java
diff options
context:
space:
mode:
authorKweku Adams <kwekua@google.com>2022-01-13 16:51:34 +0000
committerKweku Adams <kwekua@google.com>2022-01-14 16:45:02 +0000
commit9bbddb730210b524d015b8a1054b6b9a89b8eeb3 (patch)
tree69b9b054a7c456bc9749f7c085574937d1c0b42f /core/java/android/util/SparseArrayMap.java
parent16e5a4a46a1b59ebaa2055b3a608429877312b75 (diff)
Satisfy charging constraint earlier for top apps.
Several releases ago, we delayed the CHARGING broadcast to ~15 minutes after the device was plugged in. This means that any job that specifies a charging constraint won't have the constraint satisfied until 15 minutes after the device is plugged in. If such a job's setting is explicitly set by the user and the user plugs in their device while the app is on top, they will see that the work doesn't start immediately. This would be confusing for the user. We now the top app's charging constraint jobs as satisfied when the device is plugged in to avoid this confusion. If any TOP app's charging constraint jobs start while the app is on top, the job will be allowed to continue running after the user leaves the app as long as the device is plugged in. Any jobs that didn't start will be treated regularly and will have to wait for the CHARGING broadcast. Bug: 198624541 Test: atest frameworks/base/services/tests/servicestests/src/com/android/server/job Test: atest frameworks/base/services/tests/mockingservicestests/src/com/android/server/job Test: atest CtsJobSchedulerTestCases Change-Id: I914176d7bf9fd4a8998c05d411483bd4607589f2
Diffstat (limited to 'core/java/android/util/SparseArrayMap.java')
0 files changed, 0 insertions, 0 deletions