Update ImsManager to use CarrierConfigManager
Pavel Zhamaitsiak [Wed, 23 Dec 2015 00:51:57 +0000 (16:51 -0800)]
This code was not updated in branch it came from.

Change-Id: I1e9d41f0ead15c9fea8c839ff36a6bb567bf67ed

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

index 30042ac..a5c5523 100644 (file)
@@ -331,9 +331,9 @@ public class ImsManager {
 
                 if (enabled) {
                     imsManager.turnOnIms();
-                } else if (context.getResources().getBoolean(
-                        com.android.internal.R.bool.imsServiceAllowTurnOff) && (
-                        !isVolteEnabledByPlatform(context)
+                } else if (getBooleanCarrierConfig(context,
+                        CarrierConfigManager.KEY_CARRIER_ALLOW_TURNOFF_IMS_BOOL)
+                        && (!isVolteEnabledByPlatform(context)
                         || !isEnhanced4gLteModeSettingEnabledByUser(context))) {
                     log("setVtSetting() : imsServiceAllowTurnOff -> turnOffIms");
                     imsManager.turnOffIms();