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
This commit is contained in:
Torbjorn Eklund
2019-03-06 16:12:20 +01:00
parent 262b4f7434
commit 4f44b44168
3 changed files with 75 additions and 35 deletions

View File

@@ -148,7 +148,8 @@ public class WifiCallingPreferenceController extends TelephonyBasePreferenceCont
break;
}
}
preference.setSummary(resId);
preference.setSummary(
SubscriptionManager.getResourcesForSubId(mContext, mSubId).getText(resId));
}
preference.setEnabled(mCallState == TelephonyManager.CALL_STATE_IDLE);
}