Loading src/com/android/settings/ResetNetworkConfirm.java +5 −1 Original line number Diff line number Diff line Loading @@ -16,6 +16,7 @@ package com.android.settings; import android.bluetooth.BluetoothAdapter; import android.bluetooth.BluetoothManager; import android.content.Context; import android.net.ConnectivityManager; Loading Loading @@ -96,7 +97,10 @@ public class ResetNetworkConfirm extends InstrumentedFragment { BluetoothManager btManager = (BluetoothManager) context.getSystemService(Context.BLUETOOTH_SERVICE); if (btManager != null) { btManager.getAdapter().factoryReset(); BluetoothAdapter btAdapter = btManager.getAdapter(); if (btAdapter != null) { btAdapter.factoryReset(); } } ImsManager.factoryReset(context); Loading src/com/android/settings/widget/SettingsAppWidgetProvider.java +3 −0 Original line number Diff line number Diff line Loading @@ -454,6 +454,9 @@ public class SettingsAppWidgetProvider extends AppWidgetProvider { return STATE_UNKNOWN; // On emulator? } sLocalBluetoothAdapter = manager.getBluetoothAdapter(); if (sLocalBluetoothAdapter == null) { return STATE_UNKNOWN; // On emulator? } } return bluetoothStateToFiveState(sLocalBluetoothAdapter.getBluetoothState()); } Loading Loading
src/com/android/settings/ResetNetworkConfirm.java +5 −1 Original line number Diff line number Diff line Loading @@ -16,6 +16,7 @@ package com.android.settings; import android.bluetooth.BluetoothAdapter; import android.bluetooth.BluetoothManager; import android.content.Context; import android.net.ConnectivityManager; Loading Loading @@ -96,7 +97,10 @@ public class ResetNetworkConfirm extends InstrumentedFragment { BluetoothManager btManager = (BluetoothManager) context.getSystemService(Context.BLUETOOTH_SERVICE); if (btManager != null) { btManager.getAdapter().factoryReset(); BluetoothAdapter btAdapter = btManager.getAdapter(); if (btAdapter != null) { btAdapter.factoryReset(); } } ImsManager.factoryReset(context); Loading
src/com/android/settings/widget/SettingsAppWidgetProvider.java +3 −0 Original line number Diff line number Diff line Loading @@ -454,6 +454,9 @@ public class SettingsAppWidgetProvider extends AppWidgetProvider { return STATE_UNKNOWN; // On emulator? } sLocalBluetoothAdapter = manager.getBluetoothAdapter(); if (sLocalBluetoothAdapter == null) { return STATE_UNKNOWN; // On emulator? } } return bluetoothStateToFiveState(sLocalBluetoothAdapter.getBluetoothState()); } Loading