diff options
author | Evan Laird <evanlaird@google.com> | 2019-10-02 18:33:49 -0400 |
---|---|---|
committer | Evan Laird <evanlaird@google.com> | 2019-10-02 18:33:49 -0400 |
commit | 7d44291900e38e7bb3c849df95dbdd7d555f0d35 (patch) | |
tree | e65b8b6ad952692bb701514d0d6d2648829eaec3 /tools/aapt2/java/JavaClassGenerator.cpp | |
parent | 38bbedaebc4723f2f0d7ce8ce8d0f2a488292c9f (diff) |
Fix FGS lifetime extender overzealousness
ForegroundServiceLifetimeExtender was always posting MIN_FGS_TIME_MS in
the future to release a notification if it was canceled at any time
before the minimum. Meaning that if a foreground service was started and
then stopped 4.9 seconds later, it woudn't be released until 9.9 seconds
due to always posting 5000ms.
This change takes into consideration the time that a notification has
already been showing.
Fixes: 141688100
Test: atest ForegroundServiceNotificationListenerTest
Change-Id: Ie0403ddb37bb85a602a5ac6ffedcaf4bab2efcbc
Diffstat (limited to 'tools/aapt2/java/JavaClassGenerator.cpp')
0 files changed, 0 insertions, 0 deletions