Fixes the incorrect component enabled check in ShortcutService

ag/10755817 checks the enabled state of activities, but due to
b/38267327, ActivityInfo.enabled may not reflect the current state of
the component if the enabled state is changed after app is installed,
which was the root cause of cts failures. This CL checks the enabled
state via PackageManager.getComponentEnabledSetting, to cover such
cases.

Bug: 161657919
Test: atest CtsShortcutHostTestCases
Test: atest CtsShortcutManagerTestCases
Change-Id: Ide998a0fbc2c1e9fe1e77daeecc3a8c98d0425ab
1 file changed