Fix Bluetooth Settings activity memory leak.
There were two leaks in Bluetooth Settings: one when rotating the phone and other when scanning for bluetooth devices.
This commit is contained in:
@@ -188,7 +188,8 @@ public class BluetoothSettings extends PreferenceActivity
|
||||
super.onPause();
|
||||
|
||||
mLocalManager.setForegroundActivity(null);
|
||||
|
||||
mDevicePreferenceMap.clear();
|
||||
mDeviceList.removeAll();
|
||||
unregisterReceiver(mReceiver);
|
||||
|
||||
mLocalManager.unregisterCallback(this);
|
||||
|
Reference in New Issue
Block a user