Merge pull request #181 from geeksville/dev

Dev
1.2-legacy
Kevin Hester 2020-09-29 16:14:04 -07:00 zatwierdzone przez GitHub
commit f9e39b66a4
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 4AEE18F83AFDEB23
3 zmienionych plików z 8 dodań i 5 usunięć

Wyświetl plik

@ -31,7 +31,7 @@ android {
minSdkVersion 21 // The oldest emulator image I have tried is 22 (though 21 probably works)
targetSdkVersion 29
versionCode 20102 // format is Mmmss (where M is 1+the numeric major number
versionName "1.1.02"
versionName "1.1.2"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
buildTypes {

Wyświetl plik

@ -6,7 +6,6 @@ import android.app.PendingIntent
import android.bluetooth.BluetoothDevice
import android.bluetooth.BluetoothDevice.BOND_BONDED
import android.bluetooth.BluetoothDevice.BOND_BONDING
import android.bluetooth.BluetoothManager
import android.bluetooth.le.*
import android.companion.AssociationRequest
import android.companion.BluetoothDeviceFilter
@ -658,9 +657,13 @@ class SettingsFragment : ScreenFragment("Settings"), Logging {
// The device the user is already paired with is offline currently, still show it
// it in the list, but greyed out
if (!hasShownOurDevice) {
if (scanModel.selectedBluetooth != null && adapter != null && adapter.isEnabled) {
// Note: we pull this into a tempvar, because otherwise some other thread can change selectedAddress after our null check
// and before use
val bleAddr = scanModel.selectedBluetooth
if (bleAddr != null && adapter != null && adapter.isEnabled) {
val bDevice =
adapter.getRemoteDevice(scanModel.selectedBluetooth)
adapter.getRemoteDevice(bleAddr)
if (bDevice.name != null) { // ignore nodes that node have a name, that means we've lost them since they appeared
val curDevice = BTScanModel.DeviceListEntry(
bDevice.name,

@ -1 +1 @@
Subproject commit b6b1cca5ada3bc22c6b84761846e889315160db3
Subproject commit 5cdd7bff56b0ea54351e5ea0e358e864b061078f