diff options
author | Justin Koh <justinkoh@google.com> | 2012-07-31 18:32:39 -0700 |
---|---|---|
committer | Justin Koh <justinkoh@google.com> | 2012-07-31 18:32:39 -0700 |
commit | 7b065464c996b792c1ecdd9d8c93db1bf0538b8d (patch) | |
tree | 0000360297c7b8254358d1029de86934c5cd785c /src/com/android/settings/bluetooth | |
parent | 519dda9c572309182cb29e247adafe2cd475a594 (diff) | |
download | packages_apps_settings-7b065464c996b792c1ecdd9d8c93db1bf0538b8d.zip packages_apps_settings-7b065464c996b792c1ecdd9d8c93db1bf0538b8d.tar.gz packages_apps_settings-7b065464c996b792c1ecdd9d8c93db1bf0538b8d.tar.bz2 |
Move BT settings appliance check after foreground check.
Move the BT settings appliance check after the foreground activity check.
This allows us to pair bt devices if we have a UI hooked up instead of never
allowing it.
TESTED = runs on Nexus Q.
Change-Id: I3c1ea4abb8d05236d91d2525934bec757cc5ca88
Diffstat (limited to 'src/com/android/settings/bluetooth')
-rw-r--r-- | src/com/android/settings/bluetooth/LocalBluetoothPreferences.java | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/com/android/settings/bluetooth/LocalBluetoothPreferences.java b/src/com/android/settings/bluetooth/LocalBluetoothPreferences.java index 36bc7c8..6f4a765 100644 --- a/src/com/android/settings/bluetooth/LocalBluetoothPreferences.java +++ b/src/com/android/settings/bluetooth/LocalBluetoothPreferences.java @@ -64,17 +64,17 @@ final class LocalBluetoothPreferences { return false; } + // If Bluetooth Settings is visible + if (manager.isForegroundActivity()) { + return true; + } + // If in appliance mode, do not show dialog in foreground. if ((context.getResources().getConfiguration().uiMode & Configuration.UI_MODE_TYPE_APPLIANCE) == Configuration.UI_MODE_TYPE_APPLIANCE) { return false; } - // If Bluetooth Settings is visible - if (manager.isForegroundActivity()) { - return true; - } - long currentTimeMillis = System.currentTimeMillis(); SharedPreferences sharedPreferences = getSharedPreferences(context); |