The provider model slice carrier toggle is broke.

The slice doesn't upload subId for TelephonyManager and
the listeners.

Bug: 177385874
Test: (PASS)atest NetworkProviderWorkerTest
(PASS)atest ProviderModelSliceTest
(PASS)atest ProviderModelSliceHelperTest

Change-Id: Icc8a7793204de2e2eadd0454edf50e466821b8f9
This commit is contained in:
SongFerngWang
2021-01-13 22:11:49 +08:00
parent 88ffca9af9
commit f3b25cc7cb
5 changed files with 57 additions and 52 deletions

View File

@@ -115,6 +115,7 @@ public class ProviderModelSlice extends WifiSlice {
// Second section: Add a carrier item.
if (hasCarrier) {
mHelper.updateTelephony();
listBuilder.addRow(mHelper.createCarrierRow());
maxListSize--;
}
@@ -141,7 +142,7 @@ public class ProviderModelSlice extends WifiSlice {
if (worker == null || wifiList == null) {
log("wifiList is null");
int resId = R.string.non_carrier_network_unavailable;
if (!hasCarrier || mHelper.isNoCarrierData()) {
if (!hasCarrier || !mHelper.isDataSimActive()) {
log("No carrier item or no carrier data.");
resId = R.string.all_network_unavailable;
}