4 Commits

Author SHA1 Message Date
Hall Liu
9498a10f6c Merge changes from topic "fix-packagechangercvr"
* changes:
  Fix usages of PackageManager APIs in Telephony
  Fix hidden API usage in PackageChangeReceiver
2020-01-07 18:59:22 +00:00
Artur Satayev
74cb719964 Use new UnsupportedAppUsage annotation.
Existing annotations in libcore/ and frameworks/ will deleted after the migration. This also means that any java library that compiles @UnsupportedAppUsage requires a direct dependency on "unsupportedappusage" java_library.

Bug: 145132366
Test: m && diff unsupportedappusage_index.csv
Change-Id: I547d7fb2e6bc2e9707bbc0d14dc1e8cd632c5a23
2020-01-07 14:19:21 +00:00
Hall Liu
0703809472 Fix usages of PackageManager APIs in Telephony
Remove usages of the hidden PackageManager#*asUser methods from
Telephony, and add some unit tests to verify the functionality.

Test: atest FrameworksTelephonyTests
Test: atest TelephonyCommonTests
Bug: 146834818
Change-Id: I2e2ec2c421773e3ff58556373896238e1ff0678a
2020-01-06 18:21:32 -08:00
Hall Liu
35c243caa4 Clean up SmsApplication and expose getDefaultSmsPackage
- Clean up usages of hidden AppOpsManager APIs in SmsApplication
- Add unit tests for SmsApplication
- Expose RoleManager#getDefaultSmsPackage for use in SmsApplication.

Bug: 146834818
Test: atest SmsApplicationTest
Change-Id: I4ab49d7f6274389e7de7cd7223cab3c433936044
2019-12-31 14:41:02 -08:00