Commit Graph

42 Commits

Author SHA1 Message Date
Zoey Chen
b8a639f8fd [Settings] Use TelephonyManasger.registerTelephonyCallback instead of TelephonyManager.listen
Bug: 175270951
Test: make and atest
Change-Id: I15e1a199e6a34914db97055bfea9392c5bbdc9c6
2021-03-12 19:27:05 +08:00
Stanley Wang
86cc0579f3 Replace the SwitchBar with MainSwitch.
- Update wi-fi calling switch.
- Update the switches in Accessibility

Fix: 178673860
Fix: 177968565
Test: Run robotest and apply the widget in Settings and see the ui
Change-Id: Id10e6a110f418ea500a2eaf3c54752bef4f36507
2021-02-23 16:21:52 +08:00
Bonian Chen
5042276cf7 [Settings] Refactor of Wifi Calling part
Refactor of Wifi Calling to avoid accessing hidden APIs.
This includes the following cherry-picks on the corresponding files:
I455685eb26df69d929ff3ed3c26ce84aa5f6b1f8
I1a67db80b114a438afda7d45af90e54af38703c3
Idd4935a6d8ceed77c15e90f96781014d1940a427
Ia5179ee1a23f054899bc74c796542bae40cdc8d5
I57c91a095fc4d454d92e8d78e0b647b4f098c6a3
I8a09264f83b9fc4fce3f79ec3aeb6ae757b004e4
I68462368669b81e10d09bbb93e74e23ea9a1f446
I9c54eb63a0df3fde38965ee7e2ae46cc1b7efd47
I0d5dcfc33b0bddacf059d1fb9af559646e32e68a
I45977c850977be84c0dc1f6461e68a1941efc1a2
I46c047359257ddd5cb3e331add4856b01c5c9739
I35246811d3e01d0b2ca197e9a1ed7081691cd982

Bug: 140542283
Test: build pass
Change-Id: I2cddeefb7cc5f1b2060e572a73560f7cd6204d0b
2020-04-09 01:35:07 +00:00
Revathy Sivalingam
4e00cbcb2b Make URLs in Wi-Fi Calling help description clickable
Make URLs in Wi-Fi Calling help description clickable. This enables
carriers to add a link in the description that takes the user to a web
page with further information about Wi-Fi Calling.

Bug: 151326849
Test: manual
Change-Id: Icc66faa07105607a36b0d964ffc8ac5aafacb734
2020-03-13 15:51:03 +01:00
Torbjorn Eklund
4f44b44168 Consider subId when loading Wfc string resources
Consider subId when loading string resources in screen
WifiCallingSettingsForSub and Wi-Fi Calling slice.

This ensures that correct string resources is loaded in multi sim
scenario when operators are using customized strings.

Bug: 129893058
Test: make RunSettingsRoboTests ROBOTEST_FILTER=WifiCallingPreferenceController
Test: make RunSettingsRoboTests ROBOTEST_FILTER=WifiCallingSliceHelper
Change-Id: Ia5b763d4b59f7e738cb741b778bb859884a85198
2019-11-27 14:35:07 +01:00
Pooja Jain
812f8e9065 IMS: Grey out Wifi calling option when either sub is having call.
The WifiCallingSettingsForSub was not checking for call state reported
by telephony manager, hence, when call was on other sub, the option was not
getting greyed out.
Use the TelephonyManager API to fetch callstate.

Test: Manual

Bug: 130706399
Change-Id: Ib4b0e1191c83e23377ccf8ed013252728ef9dd95
2019-11-25 12:10:03 +05:30
Bonian Chen
cacf047daa [Settings] Fix conflict of AOSP merge on wifi call
Merge for fixing conflict of Ib4b0e1191c83e23377ccf8ed013252728ef9dd95

Bug: 144960427
Test: build pass
Change-Id: I2979a9a2ee1bc690486e25b7d470cf905cf02d17
Merged-In: Idb063bdab3d3b11c348804c1c0ecb268cca3068e
2019-11-22 20:38:13 +00:00
Brad Ebinger
ac4a495fc2 Merge "Fix issue that user can't edit WFC mode for SIM2" am: d2727d5d9f
am: c91d33798b

Change-Id: Icb3bd924f9e8e3e2e82845ab85ef25c2e38e13dc
2019-04-10 17:33:20 -07:00
Brad Ebinger
d2727d5d9f Merge "Fix issue that user can't edit WFC mode for SIM2" 2019-04-10 21:57:56 +00:00
Hall Liu
7e2c23aa0d Merge "Base implementation of WFC disclaimer UI" 2019-03-16 00:23:23 +00:00
manabu, shimoda
8498436a96 Base implementation of WFC disclaimer UI
Test: manual - Check that no error occurred when changing the wifi
calling settings to turn on.
Test: auto - Passed WifiCallingSettingsForSubTest,
WifiCallingDisclaimerFragmentTest and DisclaimerItemListAdapterTest.
Bug: 67872298

Change-Id: I789f530d3e16baa6e56feaa4269f6696976f747e
Merged-In: I789f530d3e16baa6e56feaa4269f6696976f747e
2019-03-15 22:57:36 +00:00
manabu, shimoda
9fae73915c Base implementation of WFC disclaimer UI
Test: manual - Check that no error occurred when changing the wifi
calling settings to turn on.
Test: auto - Passed WifiCallingSettingsForSubTest,
WifiCallingDisclaimerFragmentTest and DisclaimerItemListAdapterTest.
Bug: 67872298

Change-Id: I789f530d3e16baa6e56feaa4269f6696976f747e
2019-03-14 14:58:20 -07:00
Fan Zhang
2014d16e46 Fix robotests
Fixes: 128536554
Test: rerun robotests
Change-Id: Ife81f9d161fc416a63a9b2f04ce2ae4f9a1e74db
2019-03-13 14:31:43 -07:00
Hall Liu
13e02af2ad Merge "Add description for Wi-Fi calling mode" 2019-03-12 20:49:21 +00:00
Kazuya Ohshiro
eb57875f64 Add description for Wi-Fi calling mode
Replace the view of dialog with custom view that adds description
as summary.

Test: manual
Bug: 34793636
Change-Id: If9792b0a35c59c1260176b4b2c62107861de73b5
Merged-In: If9792b0a35c59c1260176b4b2c62107861de73b5
2019-03-12 01:42:09 +00:00
Hall Liu
843290ccb8 Merge "Add description for Wi-Fi calling mode" 2019-03-12 01:40:43 +00:00
Kazuya Ohshiro
c449048ac1 Add description for Wi-Fi calling mode
Replace the view of dialog with custom view that adds description
as summary.

Test: manual
Bug: 34793636
Change-Id: If9792b0a35c59c1260176b4b2c62107861de73b5
2019-03-11 13:21:51 -07:00
Kitta Koutarou
478e1232a0 WFC roaming mode setting can not be used with a fixed value
WFC roaming mode setting can not be used with a fixed value because it
is changed as WFC home mode changes if
KEY_EDITABLE_WFC_ROAMING_MODE_BOOL is false.

To solve this issue, separate the WFC mode setting of home and roaming.
These can switch behavior by new carrier config
KEY_USE_WFC_HOME_NETWORK_MODE_IN_ROAMING_NETWORK_BOOL.

Test: manual - Checked that WFC roaming mode is hidden if new config is
true.
Test: manual - Checked that WFC roaming mode is also changed when
change the WFC home mode if new config is true.
Test: auto - Passed WifiCallingSettingsForSubTest.
Bug: 79666081

Merged-In: Ib2363c5d50f5231cc89f287d760ca8728b02b249
Change-Id: Ib2363c5d50f5231cc89f287d760ca8728b02b249
2019-03-06 23:38:11 +00:00
Kitta Koutarou
994d27a2a5 WFC roaming mode setting can not be used with a fixed value
WFC roaming mode setting can not be used with a fixed value because it
is changed as WFC home mode changes if
KEY_EDITABLE_WFC_ROAMING_MODE_BOOL is false.

To solve this issue, separate the WFC mode setting of home and roaming.
These can switch behavior by new carrier config
KEY_USE_WFC_HOME_NETWORK_MODE_IN_ROAMING_NETWORK_BOOL.

Test: manual - Checked that WFC roaming mode is hidden if new config is
true.
Test: manual - Checked that WFC roaming mode is also changed when
change the WFC home mode if new config is true.
Test: auto - Passed WifiCallingSettingsForSubTest.
Bug: 79666081

Change-Id: Ib2363c5d50f5231cc89f287d760ca8728b02b249
2019-03-06 09:49:25 -08:00
Youming Ye
5b3ee7afaa Merge "Fix issue that the wifi calling text cannot be customized based on sim" 2019-02-22 21:53:12 +00:00
tmfang
8b414c9a14 Fix some test cases fail
Test: robo test
Fixes: 125599276
Change-Id: I4b1b15f69ff3021e4330bed49ac95ea871b98e92
2019-02-22 17:37:04 +08:00
Wenting Xiong
82aa55bcda Fix issue that the wifi calling text cannot be customized based on sim
Some carriers have requirements that the wifi calling text should be
customizable. However, the resources for the wifi calling text are
not obtained based on sim. So it cannot be customized per sim for multi
sim device. To solve this issue, obtain the resources with specified
sim.

Test: manual - Checked that the wifi calling text could be customized
based on sim.
Bug: 117257109

Change-Id: I6b3f6b06c9cc984ee6a68a19ae317b5d1d4e48e2
Merged-In: I6b3f6b06c9cc984ee6a68a19ae317b5d1d4e48e2
2019-02-22 01:57:44 +00:00
Youming Ye
da9e92c4f7 Merge "Fix issue that the wifi calling text cannot be customized based on sim" 2019-02-22 01:55:59 +00:00
Torbjorn Eklund
73ffcf4999 Close Wi-Fi Calling screen if provisioning status changes to disallow
Starts to listen for provisioning changes in Wi-Fi Calling screen and
closes the screen if the Wi-Fi Calling provisioning status changes to
disallow.

This prevents the Wi-Fi Calling screen from being kept open if the Wi-Fi
Calling provisioning status is changed to disallow while the Wi-Fi
Calling screen is open.

Bug: 119389855
Test: make RunSettingsRoboTests \
ROBOTEST_FILTER=WifiCallingSettingsForSubTest
Merged-In: I2af91c3734274f0aea942a8bb894d6f4ce295354
Change-Id: I2af91c3734274f0aea942a8bb894d6f4ce295354
2019-02-13 00:11:30 +00:00
Torbjorn Eklund
69dbf4bf84 Close Wi-Fi Calling screen if provisioning status changes to disallow
Starts to listen for provisioning changes in Wi-Fi Calling screen and
closes the screen if the Wi-Fi Calling provisioning status changes to
disallow.

This prevents the Wi-Fi Calling screen from being kept open if the Wi-Fi
Calling provisioning status is changed to disallow while the Wi-Fi
Calling screen is open.

Bug: 119389855
Test: make RunSettingsRoboTests \
ROBOTEST_FILTER=WifiCallingSettingsForSubTest
Change-Id: I2af91c3734274f0aea942a8bb894d6f4ce295354
2019-02-12 15:49:12 -08:00
Wenting Xiong
af5c05392b Fix issue that the wifi calling text cannot be customized based on sim
Some carriers have requirements that the wifi calling text should be
customizable. However, the resources for the wifi calling text are
not obtained based on sim. So it cannot be customized per sim for multi
sim device. To solve this issue, obtain the resources with specified
sim.

Test: manual - Checked that the wifi calling text could be customized
based on sim.
Bug: 117257109

Change-Id: I6b3f6b06c9cc984ee6a68a19ae317b5d1d4e48e2
2019-02-06 13:16:12 -08:00
Fan Zhang
31b210017b Migrate all MetricsProto enums to SettingsEnums
Bug: 122855168
Test: rebuild
Change-Id: I962d9a71179f86b7cae9dc5e9a00e0aa1557dc76
2019-01-17 14:55:42 -08:00
Clown SHEN
98ce7a1a7d Merge "Launch WfcActivation with subscription ID" am: bd57f94a4c am: 74fe4a9177
am: 4f2055500a

Change-Id: I326052d639276b89859770fbe110a73f80c4a9fc
2018-11-06 23:39:50 -08:00
clownshen
95f8c6e96a Launch WfcActivation with subscription ID
For multi SIM project, need to have subscription ID information in the
intent for launching WFC activation activity.

Bug: 112826472
Test: manual test
Change-Id: I9f470c014054efa612c87ff16e574fc9fd286b3d
2018-10-31 13:28:09 +08:00
xian
f32a8a955a Fix issue that user can't edit WFC mode for SIM2
User can't edit WFC mode for SIM2 even if KEY_EDITABLE_WFC_MODE_BOOL for
SIM2 is true. Because WifiCallingSettingsForSub uses subId from
PhoneStateListener. But subId of PhoneStateListener is always default
subId. So, it gets wrong carrier config values.

To fix the problem, WifiCallingSettingsForSub uses its subId.

Bug: 117193148
Test: manual - Checked that WFC preference enable/disable state change
according to the current SIM
Change-Id: I6c8f5c1009c118ae9ca9b6e690d18e11600705eb
2018-10-03 04:57:42 +00:00
Fan Zhang
de117046ad DO NOT MERGE Import clean up.
Reordered all imports according to Android codestyle.

Test: rebuild
Change-Id: I750f01f70f2114d51838bf652833aebdc4065c98
2018-09-04 13:54:46 -07:00
Aurimas Liutikas
03fcde338b Migrate Settings to androidx.
Test: make Settings
Bug: 76692459
Change-Id: I941dea40562170649bf056e675cc32e5163c0e39
Merged-In: I941dea40562170649bf056e675cc32e5163c0e39
(cherry picked from commit a290b873d0)
(cherry picked from commit b1af85d155)
2018-08-28 16:35:52 -07:00
Fan Zhang
23f8d59d02 Sort imports
Having consistent import order will reduce chance of merge
conflict between internal and external master

Test: rebuild
Change-Id: I0b1a170967ddcce7f388603fd521f6ed1eeba30b
2018-08-28 22:13:15 +00:00
Aurimas Liutikas
b1af85d155 Migrate Settings to androidx.
Test: make Settings
Bug: 76692459
Change-Id: I941dea40562170649bf056e675cc32e5163c0e39
Merged-In: I941dea40562170649bf056e675cc32e5163c0e39
(cherry picked from commit a290b873d0)
2018-08-28 11:48:56 -07:00
tmfang
41ab6b4bf8 Migrate all AlertDialogs to AndroidX version
This CL only changed AlertDialog imports.
So, reviewer can review it easily.

Change-Id: I097bc44394195b14287f4f920c570ac8653f356a
Fixes: 111413092
Test: This CL can't pass Robo test.
2018-07-20 11:32:13 +08:00
Xiangyu/Malcolm Chen
0f07f45494 Merge "Fix bug of phoneListener always listens to default subId in WFC." 2018-07-13 00:09:12 +00:00
Malcolm Chen
c68e6b3d90 Fix bug of phoneListener always listens to default subId in WFC.
In WiFi calling settings, although each WifiCallingSettingsForSub
instance has its mSubId, the mPhoneStateListener always listens to
state of default subId, which is incorrect. This is to fix that.

Bug: 109787945
Test: In DSDS device, open WFC settings. Make phone call using default
voice phone, and check that WFC setting tab of the other phone is
not greyed out.
Change-Id: I126047c6099bf156b40e0145aa55df0fdf8ef882
2018-07-12 22:32:20 +00:00
Fan Zhang
c7162cd24d Reorder and clean up imports.
Test: rebuild
Change-Id: I178485c84ae7146f991fd77b6d7504b029942a68
2018-06-18 15:45:09 -07:00
Aurimas Liutikas
e0069d332d Migrate Settings to androidx.
Test: make Settings
Bug: 76692459
Change-Id: I941dea40562170649bf056e675cc32e5163c0e39
2018-04-20 12:52:29 -07:00
Brad Ebinger
be581fd7ef Merge "Donot disable Wi-Fi Calling when getting "registration error" intent." am: 4ec0e8e865
am: 9b282e231f

Change-Id: I95a108f4e6090b61e4584a64bed58c024e120fd0
2018-03-08 19:18:08 +00:00
Fan Zhang
a00ed0aad6 Fix double help icon in wificalling screen
Change-Id: I36d4af83e1cb7fd77b360829baab2004422488c6
Fixes: 71538192
Test: robotests
2018-03-05 13:19:46 -08:00
Fan Zhang
b91db42100 Fix double search icon in wifi calling page
- Moved fragments into wifi sub-package.
- Cleaned up inheritance for WifiCallingSettings
- Attach help and search action menu controller correctly.

Change-Id: I0bc8ab99df5d8c5ea64fb64de5ae70c2c9bd6f31
Fixes: 72958674
Test: robotest
2018-02-09 11:26:16 -08:00