Adding switch for Forced App Standby
Reusing the 'Background activity' switch found in App Info. The switch
now needs to be shown for all apps and will toggle another app op
RUN_ANY_IN_BACKGROUND which controls whether jobs or alarms are run for
background apps.
Also fixed handling of multiple packages with shared uid. The controller
was picking the first package for uid but the order of packages can
change on a reboot which would cause wrong app ops settings across
packages of the same uid.
Test: make -j32 RunSettingsRoboTests
Bug: 65176793
Change-Id: I2a9b96bc02730776172c3ae317cb7f7f890bec30
4 files changed