summaryrefslogtreecommitdiff
path: root/tools/aapt2/diff/Diff.cpp
diff options
context:
space:
mode:
authorFelipe Leme <felipeal@google.com>2016-05-24 13:06:54 -0700
committerFelipe Leme <felipeal@google.com>2016-05-27 11:45:09 -0700
commita1b79bfd7a15006a93da933695359765e0fee495 (patch)
tree3177b01166825fc941d68a3444638e71db8e7f29 /tools/aapt2/diff/Diff.cpp
parentbd34103c5defbfd180be6a387eb5aa82d4b97eac (diff)
Allow apps to bypass Power Save restrictions when launched from a Notification's PendingIntent.
This scenario typically happens when the device is on Doze Mode and a notification action is triggered from a Wear device. In a nutshell, the workflow is: - ProcessRecord has a flag telling whether a process has "whitelist management" privileges. - When NotificationManager binds a new NotificationListenerService, it sets the BIND_ALLOW_WHITELIST_MANAGEMENT flag. - On bind(), ActiveService asserts that only system apps can set that flag. - On computeOomAdjLocked(), ActivityManagerService sets the ProcessRecord flag if necessary. - Upon creating a notification, NotificationManager calls AM to mark its PendingIntents as coming from a notification. - When PendingIntentRecord sends it to the target, it checks if it's from a notification and if so calls AM to do the temp whitelist. - On unbind(), ActiveService removes the ProcessRecord flag if necessary. Fixes: 28818704 Change-Id: I00d46036a2cbb73f7f733fd35bf0b743a02807a1
Diffstat (limited to 'tools/aapt2/diff/Diff.cpp')
0 files changed, 0 insertions, 0 deletions