Bluetooth : fix for Settings crashes while rotating the screen.
- Add some codes preventing setting crash when rotating the screen when the Rename device or Visibility timeout dialogs are visible. Change-Id: I5e142a5d869a0d5c91c6ace80093d09178d79558 Signed-off-by: jhtop.kim <jhtop.kim@samsung.com>
This commit is contained in:
@@ -194,12 +194,12 @@ public final class BluetoothSettings extends DeviceListPreferenceFragment {
|
||||
return true;
|
||||
|
||||
case MENU_ID_RENAME_DEVICE:
|
||||
new BluetoothNameDialogFragment(mLocalAdapter).show(
|
||||
new BluetoothNameDialogFragment().show(
|
||||
getFragmentManager(), "rename device");
|
||||
return true;
|
||||
|
||||
case MENU_ID_VISIBILITY_TIMEOUT:
|
||||
new BluetoothVisibilityTimeoutFragment(mDiscoverableEnabler).show(
|
||||
new BluetoothVisibilityTimeoutFragment().show(
|
||||
getFragmentManager(), "visibility timeout");
|
||||
return true;
|
||||
|
||||
@@ -261,6 +261,8 @@ public final class BluetoothSettings extends DeviceListPreferenceFragment {
|
||||
mDiscoverableEnabler = new BluetoothDiscoverableEnabler(getActivity(),
|
||||
mLocalAdapter, mMyDevicePreference);
|
||||
mDiscoverableEnabler.resume();
|
||||
LocalBluetoothManager.getInstance(getActivity()).setDiscoverableEnabler(
|
||||
mDiscoverableEnabler);
|
||||
}
|
||||
|
||||
// Paired devices category
|
||||
|
Reference in New Issue
Block a user