ImsManager: updateWfcFeatureAndProvisionedValues use roaming state
Meng Wang [Thu, 6 Oct 2016 18:29:46 +0000 (11:29 -0700)]
In updateImsServiceConfig, WFC should be updated according to roaming
state. Roaming-aware version of getWfcMode() should be used.

Bug: 31972897
Change-Id: Ic4d6a516373d6ccdadad4fd43ed9e092d8ef72a6

src/java/com/android/ims/ImsManager.java

index 5630af1..6d8cef6 100644 (file)
@@ -820,9 +820,10 @@ public class ImsManager {
      * @throws ImsException
      */
     private boolean updateWfcFeatureAndProvisionedValues() throws ImsException {
+        boolean isNetworkRoaming = TelephonyManager.getDefault().isNetworkRoaming();
         boolean available = isWfcEnabledByPlatform(mContext);
         boolean enabled = isWfcEnabledByUser(mContext);
-        int mode = getWfcMode(mContext);
+        int mode = getWfcMode(mContext, isNetworkRoaming);
         boolean roaming = isWfcRoamingEnabledByUser(mContext);
         boolean isFeatureOn = available && enabled;