Merge branch \'mnc-dr-dev-plus-aosp\' of /usr/local/google/game/mirror/googleplex-android_googlesource_com/platform/packages/apps/Settings into mnc-dr-dev-plus-aosp
am: ead9448b4a
* commit 'ead9448b4a9284543e875115dde389444f2e2e3e':
Always show pairing dialog for device-specific keyboard.
This commit is contained in:
@@ -65,8 +65,10 @@ public final class BluetoothPairingRequest extends BroadcastReceiver {
|
||||
PowerManager powerManager =
|
||||
(PowerManager)context.getSystemService(Context.POWER_SERVICE);
|
||||
String deviceAddress = device != null ? device.getAddress() : null;
|
||||
if (powerManager.isScreenOn() &&
|
||||
LocalBluetoothPreferences.shouldShowDialogInForeground(context, deviceAddress)) {
|
||||
String deviceName = device != null ? device.getName() : null;
|
||||
boolean shouldShowDialog= LocalBluetoothPreferences.shouldShowDialogInForeground(
|
||||
context, deviceAddress, deviceName);
|
||||
if (powerManager.isInteractive() && shouldShowDialog) {
|
||||
// Since the screen is on and the BT-related activity is in the foreground,
|
||||
// just open the dialog
|
||||
context.startActivity(pairingIntent);
|
||||
|
Reference in New Issue
Block a user