Merge "Don't cancel passkey entry pairing autonomously" into tm-dev am: f073d27097

Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/19423651

Change-Id: I71ca4f0c9ab8e37c63ecd21783714488c27bbd5c
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
Himanshu Rawat
2022-08-09 07:04:58 +00:00
committed by Automerger Merge Worker

View File

@@ -86,8 +86,12 @@ public class BluetoothPairingDialogFragment extends InstrumentedDialogFragment i
@Override
public void onDestroy() {
super.onDestroy();
if (!mPositiveClicked) {
mPairingController.onCancel();
if (mPairingController.getDialogType()
!= BluetoothPairingController.DISPLAY_PASSKEY_DIALOG) {
/* Cancel pairing unless explicitly accepted by user */
if (!mPositiveClicked) {
mPairingController.onCancel();
}
}
}