Skip to content

Commit

Permalink
updated list on refresh
Browse files Browse the repository at this point in the history
  • Loading branch information
r-cohen committed Mar 19, 2018
1 parent b343c6d commit 6203f73
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -32,15 +32,15 @@ private void updateIconResId() {
iconResourceId = R.drawable.network_high;
return;
}
if (rssi <= -50 && rssi > -67) {
if (rssi <= -50 && rssi > -70) {
iconResourceId = R.drawable.network_medium;
return;
}
if (rssi <= -67 && rssi > -70) {
if (rssi <= -70 && rssi > -90) {
iconResourceId = R.drawable.network_low;
return;
}
if (rssi <= -70) {
if (rssi <= -90) {
iconResourceId = R.drawable.network_no_signal;
return;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,7 @@ public int compare(BTScanResultItem btScanResultItem, BTScanResultItem t1) {

void refresh() {
if (!isScanning()) {
devices = new ArrayList<>();
BluetoothAdapter.getDefaultAdapter().startDiscovery();
}
}
Expand Down

0 comments on commit 6203f73

Please sign in to comment.