Commit Graph

6053 Commits

Author SHA1 Message Date
Grace Jia
e2099469d2 Add support for selected contacts device to device sharing.
Bug: 163085177
Test: CTS tests
Change-Id: I4f6da463a29ba9cf067d36941a9b4e584012c817
Merged-In: I4f6da463a29ba9cf067d36941a9b4e584012c817
2021-05-03 12:19:27 -07:00
Jayachandran Chinnakkannu
1fe2aa14c4 Add new provisioning flag for VOIMS opt-in
Bug: 177009570
Test: By Manual
1. Call setProvisioningIntValue() and getProvisioningIntValue()

2. Enable/disable the value and dial a VoLTE call
2-1. Set value to 1
2-2. Dial a call
2-3. From ImsPhoneCallTracker and GsmCdmaPhone's log, VoLTE is
 registered and device is trying IMS PS call
2-4. Set value to 0
2-5. Dial a call
2-6. From ImsPhoneCallTracker and GsmCdmaPhone's log, VoLTE is
unregistered and device is trying (non-IMS) CS call

3. atest

Change-Id: I0b8af8fe6c9a34a56f9e2275df0a03ba093f439e
Merged-In: I0b8af8fe6c9a34a56f9e2275df0a03ba093f439e
2021-04-29 08:25:21 +00:00
Grace Jia
d5eb6fb0ef Add D2D sharing level setting APIs.
Test: unit test, cts test
Bug: 163085177
Change-Id: I86f88d68c8629a0329dcde7b2d17928cacec37e7
Merged-In: I86f88d68c8629a0329dcde7b2d17928cacec37e7
2021-04-29 15:27:42 +08:00
Marcus Hagerott
e738f2f211 Merge "Improve SimPhonebookContract javadocs and qualifiers" 2021-04-07 15:43:33 +00:00
Marcus Hagerott
a6c9cd2fb7 Improve SimPhonebookContract javadocs and qualifiers
Test: atest CtsSimPhonebookProviderTestCases
Bug: 183395170
Change-Id: Id160092078f26908787b4b9a4fbe525825496875
2021-03-24 14:16:31 -07:00
Peter Wang
e0dcbf7c3f [API Review] Change ACTION_MANAGE_ALL_SIM_PROFILE_SETTINGS API
Bug: 182165190
Bug: 170507492
Test: Local
Change-Id: I21bd95bfc746f2d11dc569b9ea990bb7a3726ba5
Merged-In: I21bd95bfc746f2d11dc569b9ea990bb7a3726ba5
2021-03-24 11:18:37 -07:00
Rambo Wang
cff9760e07 Export ServiceState#DataRegState into telephony provider
Keep ServiceState#getDataRegState hide. Apps can get the same
info from telephony provider without loation permission.

Bug: 182601774
Test: atest com.android.phone.ServiceStateProviderTest
Change-Id: I1ba72a5b767761d2f7bd1b52459a0c9d101061a2
2021-03-23 09:33:21 -07:00
Rambo Wang
4481b5181e Public ServiceState#duplexMode in telephony provider
ServiceState#getDuplexMode is a public API. Expose the same
info through telephony provider to let applications retreive
it without location permission.

Bug: 182601774
Test: atest com.android.phone.ServiceStateProviderTest
Change-Id: I19128c938993f351533aca9a8e1a1356e21eb30e
2021-03-23 09:27:42 -07:00
Rambo Wang
6a7df3f4e8 Expose ServiceState#getDataNetworkType in telephony provider
Data network type is key information to make the switching
decision. Exporting to telephony provider can let application
get the information without location permission.

Bug: 182601774
Test: atest com.android.phone.ServiceStateProviderTest
Change-Id: I9753eee2619baf6b1627835624444c0e4f0cd410
2021-03-22 12:24:19 -07:00
Yomna Nasser
1de59a9c59 Implementation of "Enable 2G" for Settings.
(1) Adds KEY_HIDE_ENABLE_2G_BOOL to CarrierConfigManager, and
(2) Adds new reason ALLOWED_NETWORK_TYPES_REASON_ENABLE_2G.

Test: manual & atest -c Enable2gPreferenceControllerTest
Bug: b/163168917
Change-Id: I81052549f8dde491697c35365320145fd24c3842
Merged-In: I81052549f8dde491697c35365320145fd24c3842
2021-03-17 20:21:21 +08:00
SongFerng Wang
b332627a15 Merge "Improve AllowedNetworkTypesForReason and refactor PreferredNetworkType" 2021-03-05 01:59:53 +00:00
SongFerngWang
e206456a16 Improve AllowedNetworkTypesForReason and refactor PreferredNetworkType
- Add more reasons of allowed network type
  - ALLOWED_NETWORK_TYPES_REASON_USER
  - ALLOWED_NETWORK_TYPES_REASON_CARRIER
- Add @systemApi for below
  - ALLOWED_NETWORK_TYPES_REASON_USER
  - ALLOWED_NETWORK_TYPES_REASON_POWER
  - ALLOWED_NETWORK_TYPES_REASON_CARRIER
  - setAllowedNetworkTypesForReason API
  - getAllowedNetworkTypesForReason API
  - getAllowedNetworkTypesBitmask API
- Add Public for below
  - CARRIER_NR_AVAILABILITY_NONE
  - CARRIER_NR_AVAILABILITY_NSA
  - CARRIER_NR_AVAILABILITY_SA
  - KEY_CARRIER_NR_AVAILABILITY_INT
- @Deprecated API
  - setPreferredNetworkTypeBitmask
  - getPreferredNetworkTypeBitmask
  - setAllowedNetworkType
  - getAllowedNetworkType
- Add a new way to notify allowedNetworkType at PhoneStateListener
- Replace KEY_NR_ENABLED_BOOL with KEY_CARRIER_NR_AVAILABILITY_INT

Bug: 161434786
Test: atest TelephonyManagerTest#testSetAllowedNetworkTypesForReason
(PASS)
atest TelephonyManagerTest#\
testSetAllowedNetworkTypesForReason_moreReason
(PASS)
atest PhoneStateListenerTest#\
testOnAllowedNetworkTypesChangedByRegisterPhoneStateListener
(PASS)

Change-Id: I3d0c119a0c2a30c56b0c127ba6525f8992b4e9dd
Merged-In: I3d0c119a0c2a30c56b0c127ba6525f8992b4e9dd
2021-03-04 14:58:54 +08:00
Xin Li
1af6a12e98 Merge "Merge RQ2A.210305.007" 2021-03-03 21:41:39 +00:00
Paul Hu
18a60acfdf Merge "Implement Settings#checkAndNoteChangeNetworkStateOperation on CS" 2021-03-03 01:07:20 +00:00
Xin Li
4bbe2a2df3 Merge RQ2A.210305.007 into stage.
Bug: 180401296
Merged-In: I1a16808426934f4a8d12410576d769443e4c2a04
Change-Id: I247a99c33c62cd1d000b7e50d1dda8b14df229d7
2021-03-01 01:06:43 -08:00
Marcus Hagerott
dc54e7afdf Merge "Add more detail to javadocs for SimPhonebookContract" am: 57a0af04c5
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1596935

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Id968da9f8ec6ada50d674def708662383bf6b382
2021-02-24 01:22:51 +00:00
paulhu
0a2317a308 Implement Settings#checkAndNoteChangeNetworkStateOperation on CS
Connectivity is becoming a mainline module in S and
ConnectivityManager#enforceChangePermission is using
Settings#checkAndNoteChangeNetworkStateOperation for performing a
strict and comprehensive check of whether a calling package is
allowed to change the state of network. However, Mainline modules
are not allowed to use non-formal APIs, fortunately CS is the
only caller of this ConnectivityManager#enforceChangePermission.
Thus, implement the Settings API on ConnectivityService and remove
the ConnectivityManager#enforceChangePermission and
Settings#checkAndNoteChangeNetworkStateOperation.

Bug: 178565313
Test: atest FrameworksNetTests
Change-Id: I6f03398c1735b89470ad5bdbe3a036929daeb53c
Merged-In: I6f03398c1735b89470ad5bdbe3a036929daeb53c
2021-02-23 08:35:38 +00:00
Marcus Hagerott
42a163c89e Add more detail to javadocs for SimPhonebookContract
This provides more details about the operations supported by the provider.

Test: none
Bug: 154363919
Change-Id: I90147f5dd2b55be52089c854464ca4c52f4ba5a7
2021-02-22 16:39:27 -08:00
Xin Li
be473bf819 Merge ab/7061308 into stage.
Bug: 180401296
Merged-In: I4bf82035631ccff6d5a6144d6d9b1d203b076851
Change-Id: I1b5f3a672a55eaabba0f5389bab110b395553559
2021-02-21 09:39:53 -08:00
Jooyung Han
8ab5cf670f Fix self-assign error in SimPhonebookContract
Bug: 180472752
Test: atest
FrameworksTelephonyTests: com.android.internal.telephony.uicc.IccUtilsTest
TeleServiceTests: SimPhonebookProviderTest
Change-Id: I1a8c0dabee3ca90fcdeca263a4c943e01fbae75e
2021-02-17 18:27:59 +09:00
Marcus Hagerott
407164df11 Add UCS-2 support for SimPhonebookContract
This simplifies the API by eliminating the need to attempt to detect
and report unsupported characters.

Test: atest FrameworksTelephonyTests:com.android.internal.telephony.uicc.IccUtilsTest TeleServiceTests:SimPhonebookProviderTest
Bug: 154363919
Change-Id: Ica8f3a642ee50ca81c43822ba39c0a071c279705
2021-02-16 06:47:23 -08:00
Marcus Hagerott
1edf43e23d Adding SimPhonebookContract
This is a contract class for a provider that reads contacts from the SIM
card.

Bug: 154363919
Test: atest CtsSimPhonebookProviderTestCases CtsSimPhonebookProviderNoSimTestCases
Change-Id: I584150dd8352dbb49d70ea28c6d064a6336d018d
2021-02-01 09:18:16 -08:00
Peter Wang
9e1f4ec8c3 Add an API for LPA (SIM Manager) to bring up pages related to managing SIM profiles.
Bug: 170507492
Test: Build
Change-Id: I8a2c4e86cb3ffd6ef0dac03ec2e4968839202e7d
Merged-In: I8a2c4e86cb3ffd6ef0dac03ec2e4968839202e7d
2021-01-15 11:15:19 -08:00
Treehugger Robot
7ae76a2f3f Merge "Add feature flag for app hibernation." 2021-01-14 00:01:19 +00:00
Patrick Rohr
048bc5ea80 Add Restricted Mode handling to NetworkPolicyManager
Adds Restricted Mode functionality to NetworkPolicyManager. When this
mode is turned on (via setting), only apps with
android.permission.CONNECTIVITY_USE_RESTRICTED_NETWORKS will be able to
use the network. For all other apps, the network will be blocked by the
firewall. This is controlled by a new allowlist firewall chain
fw_restricted_mode.

As a first step, this implementation still requires a reboot after the
enabling / disabling the mode to take effect. I will provide the dynamic
configuration in the next CL.

Test: atest CtsHostsideNetworkTests && atest
NetworkPolicyManagerServiceTest
Bug: 170322816
Bug: 157505406
Bug: 170322455
Bug: 175281879

Exempt-From-Owner-Approval: Change already merged on internal gerrit.
Change-Id: I0731fa842c69683953baaf9ec3a9a03454f4c607
Merged-In: I0731fa842c69683953baaf9ec3a9a03454f4c607
2021-01-12 11:59:17 +00:00
Kevin Han
f62a11079f Add feature flag for app hibernation.
Add feature flag for app hibernation so that we can begin implementing
behind a feature flag.

We use DeviceConfig as per instructions at go/android-flags-setup so
that we may eventually roll this out to dogfood devices using P/H and
Mendel.

Bug: 175829330
Test: Builds
Change-Id: I5c140ee6b20c887c9513f76254f752b1a9455a8a
Merged-In: I27b4bdd9b6ed25b06fc685183f0dc872094f1b5c
2021-01-11 13:46:33 -08:00
Varun Shah
e39e554494 DO NOT MERGE: Disable StrictMode VM Policy check.
Disable the VM policy violation for intents that contain a content URI
but don't have FLAG_GRANT_URI_PERMISSION when scheduling alarms.

Fixes: 160426113
Test: atest CalendarProvider2Test
Change-Id: If6e4a03609fc3d03dde66bcaa3136b23662ccaeb
(cherry picked from commit 224822ecaf)
(cherry picked from commit f20d333ada)
2021-01-09 01:49:21 +00:00
Andrei Onea
46111c8ea0 Add force_non_debuggable_final_build_for_compat
This flag forces the compat framework to assume we're on a
non-debuggable build, and use stricter rules for enforcing
the change id override policy.
On a non-debuggable build, this flag has no effect.

Test: atest OverrideValidatorImplTest
Bug: 158696818
Change-Id: I3b13f1898e7ff00580140debe2ced9f8074502ea
2020-12-30 14:52:51 +00:00
Treehugger Robot
03b5b82cdf Merge "Add SettingsProvider team as OWNERS of android.provider.Settings" am: d83aa0243b am: f3b68805b1
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1535814

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I301c695f862fee869d6dba3eaf6966ba273fc3ca
2020-12-23 21:38:56 +00:00
Jeff DeCew
9f74d0a408 Add SettingsProvider team as OWNERS of android.provider.Settings
Change-Id: Ifa4a11780bb934f7b644ad150f3c09493b23f9f4
2020-12-23 16:35:05 +00:00
Allen Su
2fc4cc29bc Merge "[RCS]Add new carrier configs for presence" am: f2fdcff51e am: 992b4ffdf8
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1511319

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I2cf63aec6a876ca56a464f02e0ce7997ecd94b01
2020-12-22 01:35:07 +00:00
Allen Su
f2fdcff51e Merge "[RCS]Add new carrier configs for presence" 2020-12-22 00:26:52 +00:00
Hui Wang
ec8bb25be6 Merge "RCS Provisioning APIs for Single Registration" am: 7c9eef5613 am: 81b3cfc4fe
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1532778

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ic7bcf565faab1a95185f0b6ecdcc6e9dd8c03e53
2020-12-17 23:18:25 +00:00
Hui Wang
7c9eef5613 Merge "RCS Provisioning APIs for Single Registration" 2020-12-17 22:53:31 +00:00
Hui Wang
e92ddfef4f RCS Provisioning APIs for Single Registration
Bug: 154864150
Test: atest FrameworksTelephonyTests:com.telephony.ims.RcsConfigTest
Test: atest TeleServiceTests:com.android.phone.RcsProvisioningMonitorTest
Test: atest CtsTelephonyTestCases:android.telephony.ims.cts.ImsServiceTest
Merged-In: Ie9445dd450d175e0dc94b63b487dda5cde729123
Change-Id: Ie9445dd450d175e0dc94b63b487dda5cde729123
2020-12-17 17:13:24 +00:00
Hui Wang
a82cdddff4 Merge "Added cross sim calling settings support" am: 7f6a8a9648 am: aa7996126a
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1532259

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I7e2954338461b79f069c5efc6f15acb38c0538fc
2020-12-17 16:52:04 +00:00
Hui Wang
7f6a8a9648 Merge "Added cross sim calling settings support" 2020-12-17 15:14:42 +00:00
Hui Wang
ce026fd5b9 Added cross sim calling settings support
Added a telephony provider entry for storing the
user's settings.

Fix: 173250681
Test: Manual
Merged-In: I081c7e5fcc98f51a97c41a0a9a2b9b628c8d0415
Change-Id: I081c7e5fcc98f51a97c41a0a9a2b9b628c8d0415
2020-12-17 00:57:18 +00:00
Jeff Sharkey
95dfa1a859 Merge "Additional OWNERS coverage for storage." am: d111833fd3 am: c7077507d0
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1531982

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ic8835ec5c6b26fa726ea83801e7ffb4d706dd4df
2020-12-16 22:33:44 +00:00
Jeff Sharkey
9ac773a60b Additional OWNERS coverage for storage.
Bug: 174932174
Test: none
Change-Id: I265ebd077d27d0d52d97a2c3c4a7147368be2498
2020-12-16 14:47:45 -07:00
Tianjie Xu
2fd269494a Merge changes Icf10d577,Ia9d3cae7 am: 6083210d17 am: a258be9df5
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1519582

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I12512a441b330e062fe8e8d482a367e719c7d45d
2020-12-15 00:03:48 +00:00
Tianjie Xu
6083210d17 Merge changes Icf10d577,Ia9d3cae7
* changes:
  Factor out a class to store the rebootEscrow key
  Add namespace in DeviceConfig to support ota teams's features
2020-12-14 22:58:46 +00:00
Tianjie
e315bfa55b Add namespace in DeviceConfig to support ota teams's features
One sample usage is to toggle between server based or HAL based
implementation for resume on reboot.

Bug: 172780686
Test: adb shell device_config put ota server_based_ror_enabled true;
Check the value in system server code

Change-Id: Ia9d3cae788e9316850ce1fc417c12b5fc109b1a3
2020-12-14 11:21:17 -08:00
allenwtsu
e6ddc2fb14 [RCS]Add new carrier configs for presence
KEY_ENABLE_PRESENCE_CAPABILITY_EXCHANGE_BOOL
KEY_RCS_BULK_CAPABILITY_EXCHANGE_BOOL
KEY_ENABLE_PRESENCE_GROUP_SUBSCRIBE_BOOL

Bug: 173828080
Test: build pass
Change-Id: I8e0f1ea824e8f9fdf409adb821325185b8ba457d
2020-12-11 23:59:30 +08:00
Jeff Sharkey
358f0d4fc8 Merge changes from topic "dec5" am: c2793cf12b am: 9af6ac78b0
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1519384

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I2776a545a24f007ccb4b9ee14705978571265ef3
2020-12-08 16:43:19 +00:00
Jeff Sharkey
9af6ac78b0 Merge changes from topic "dec5" am: c2793cf12b
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1519384

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ifdc390f5ae046c515a30158f3f55b831be147547
2020-12-08 16:05:11 +00:00
Jeff Sharkey
52b9862f87 Improve OWNERS coverage across frameworks/base/.
As general background, OWNERS files expedite code reviews by helping
code authors quickly find relevant reviewers, and they also ensure
that stakeholders are involved in code changes in their areas.

Some teams under frameworks/base/ have been using OWNERS files
successfully for many years, and we're ready to expand them to cover
more areas.  Here's the historical coverage statistics for the last
two years of changes before these new OWNERS changes land:

-- 56% of changes are fully covered by OWNERS
-- 17% of changes are partially covered by OWNERS
-- 25% of changes have no OWNERS coverage

Working closely with team leads, we've now identified clear OWNERS on
a per-package basis, and we're using "include" directives whenever
possible to to simplify future maintenance.  With this extensive
effort, we've now improved our coverage as follows:

-- 98% of changes are fully covered by OWNERS
-- 1% of changes are partially covered by OWNERS
-- 1% of changes have no OWNERS coverage

This specific change is automatically generated by a script that
identifies relevant "include" directives.

Bug: 174932174
Test: manual
Exempt-From-Owner-Approval: refactoring with team leads buy-in
Merged-In: I3480ddf2fe7ba3dfb922b459d4da01fa17a2c813
Change-Id: I3480ddf2fe7ba3dfb922b459d4da01fa17a2c813
2020-12-08 08:36:28 -07:00
Xin Li
8836e88707 DO NOT MERGE - Merge RQ1A.201205.011
Bug: 172690556
Merged-In: I26bed08456197721d07f2fab563be0c54e43efd2
Change-Id: Ic1ac100efa50687ccfcbb87ee91a57703105afad
2020-12-07 00:39:42 -08:00
Xin Li
d31ee38811 Merge rvc-qpr-dev-plus-aosp-without-vendor@6881855
Bug: 172690556
Merged-In: I78222391b83a4add8e964340ec08bb8a1306e1c6
Change-Id: I28bbf40820674675ccf765c912aa8140d3f74ab2
2020-12-02 00:38:58 -08:00
Songchun Fan
59e16410cc Merge "[DeviceConfig] add schfan to OWNERS" am: 12fc9f58a4 am: 0aec249264 am: 92babaa746
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1503393

Change-Id: Iddf5d4c50c2da392e63eb84627525936346b273b
2020-11-18 23:42:20 +00:00