Merge "WiFiCallingSettings: don't start carrier app in onResume" am: 05c88316ec
am: e21cbcb6b4
am: 556e3bb3e8
Change-Id: I1a189c49f1ca8c0a8c12f1c834d90f61d25fc470
This commit is contained in:
@@ -252,15 +252,6 @@ public class WifiCallingSettings extends SettingsPreferenceFragment
|
|||||||
|
|
||||||
final Context context = getActivity();
|
final Context context = getActivity();
|
||||||
|
|
||||||
if (ImsManager.isWfcEnabledByPlatform(context)) {
|
|
||||||
TelephonyManager tm = (TelephonyManager) getSystemService(Context.TELEPHONY_SERVICE);
|
|
||||||
tm.listen(mPhoneStateListener, PhoneStateListener.LISTEN_CALL_STATE);
|
|
||||||
|
|
||||||
mSwitchBar.addOnSwitchChangeListener(this);
|
|
||||||
|
|
||||||
mValidListener = true;
|
|
||||||
}
|
|
||||||
|
|
||||||
// NOTE: Buttons will be enabled/disabled in mPhoneStateListener
|
// NOTE: Buttons will be enabled/disabled in mPhoneStateListener
|
||||||
boolean wfcEnabled = ImsManager.isWfcEnabledByUser(context)
|
boolean wfcEnabled = ImsManager.isWfcEnabledByUser(context)
|
||||||
&& ImsManager.isNonTtyOrTtyOnVolteEnabled(context);
|
&& ImsManager.isNonTtyOrTtyOnVolteEnabled(context);
|
||||||
@@ -271,6 +262,15 @@ public class WifiCallingSettings extends SettingsPreferenceFragment
|
|||||||
mButtonWfcRoamingMode.setValue(Integer.toString(wfcRoamingMode));
|
mButtonWfcRoamingMode.setValue(Integer.toString(wfcRoamingMode));
|
||||||
updateButtonWfcMode(context, wfcEnabled, wfcMode, wfcRoamingMode);
|
updateButtonWfcMode(context, wfcEnabled, wfcMode, wfcRoamingMode);
|
||||||
|
|
||||||
|
if (ImsManager.isWfcEnabledByPlatform(context)) {
|
||||||
|
TelephonyManager tm = (TelephonyManager) getSystemService(Context.TELEPHONY_SERVICE);
|
||||||
|
tm.listen(mPhoneStateListener, PhoneStateListener.LISTEN_CALL_STATE);
|
||||||
|
|
||||||
|
mSwitchBar.addOnSwitchChangeListener(this);
|
||||||
|
|
||||||
|
mValidListener = true;
|
||||||
|
}
|
||||||
|
|
||||||
context.registerReceiver(mIntentReceiver, mIntentFilter);
|
context.registerReceiver(mIntentReceiver, mIntentFilter);
|
||||||
|
|
||||||
Intent intent = getActivity().getIntent();
|
Intent intent = getActivity().getIntent();
|
||||||
|
Reference in New Issue
Block a user