Loading aconfig/settings_bluetooth_declarations.aconfig +10 −0 Original line number Diff line number Diff line Loading @@ -31,3 +31,13 @@ flag { description: "Gates whether to enable bluetooth device details polish" bug: "343317785" } flag { name: "disable_bonding_cancellation_for_orientation_change" namespace: "cross_device_experiences" description: "Stop cancelling bonding process when there is an orientation change" bug: "349542301" metadata { purpose: PURPOSE_BUGFIX } } src/com/android/settings/bluetooth/BluetoothPairingDialogFragment.java +10 −6 Original line number Diff line number Diff line Loading @@ -41,6 +41,7 @@ import androidx.appcompat.app.AlertDialog; import com.android.settings.R; import com.android.settings.core.instrumentation.InstrumentedDialogFragment; import com.android.settings.flags.Flags; /** * A dialogFragment used by {@link BluetoothPairingDialog} to create an appropriately styled dialog Loading Loading @@ -87,14 +88,17 @@ public class BluetoothPairingDialogFragment extends InstrumentedDialogFragment i @Override public void onDestroy() { super.onDestroy(); if (mPairingController.getDialogType() != BluetoothPairingController.DISPLAY_PASSKEY_DIALOG) { /* Cancel pairing unless explicitly accepted by user */ if (!mPositiveClicked) { /* Cancel pairing unless 1) explicitly accepted by user 2) the event is triggered by * orientation change. */ boolean shouldCancelPairing = Flags.disableBondingCancellationForOrientationChange() ? !mPositiveClicked && !getActivity().isChangingConfigurations() : !mPositiveClicked; if (mPairingController.getDialogType() != BluetoothPairingController.DISPLAY_PASSKEY_DIALOG && shouldCancelPairing) { mPairingController.onCancel(); } } } @Override public void beforeTextChanged(CharSequence s, int start, int count, int after) { Loading Loading
aconfig/settings_bluetooth_declarations.aconfig +10 −0 Original line number Diff line number Diff line Loading @@ -31,3 +31,13 @@ flag { description: "Gates whether to enable bluetooth device details polish" bug: "343317785" } flag { name: "disable_bonding_cancellation_for_orientation_change" namespace: "cross_device_experiences" description: "Stop cancelling bonding process when there is an orientation change" bug: "349542301" metadata { purpose: PURPOSE_BUGFIX } }
src/com/android/settings/bluetooth/BluetoothPairingDialogFragment.java +10 −6 Original line number Diff line number Diff line Loading @@ -41,6 +41,7 @@ import androidx.appcompat.app.AlertDialog; import com.android.settings.R; import com.android.settings.core.instrumentation.InstrumentedDialogFragment; import com.android.settings.flags.Flags; /** * A dialogFragment used by {@link BluetoothPairingDialog} to create an appropriately styled dialog Loading Loading @@ -87,14 +88,17 @@ public class BluetoothPairingDialogFragment extends InstrumentedDialogFragment i @Override public void onDestroy() { super.onDestroy(); if (mPairingController.getDialogType() != BluetoothPairingController.DISPLAY_PASSKEY_DIALOG) { /* Cancel pairing unless explicitly accepted by user */ if (!mPositiveClicked) { /* Cancel pairing unless 1) explicitly accepted by user 2) the event is triggered by * orientation change. */ boolean shouldCancelPairing = Flags.disableBondingCancellationForOrientationChange() ? !mPositiveClicked && !getActivity().isChangingConfigurations() : !mPositiveClicked; if (mPairingController.getDialogType() != BluetoothPairingController.DISPLAY_PASSKEY_DIALOG && shouldCancelPairing) { mPairingController.onCancel(); } } } @Override public void beforeTextChanged(CharSequence s, int start, int count, int after) { Loading