mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge
synced 2024-08-24 16:21:16 +02:00
add isConnecting() method to GBDevice
This commit is contained in:
parent
4a1a1d59be
commit
cd0139cd7c
@ -161,7 +161,7 @@ public class ControlCenter extends Activity {
|
||||
private void refreshPairedDevices() {
|
||||
GBDevice connectedDevice = null;
|
||||
for (GBDevice device : deviceList) {
|
||||
if (device.isConnected()) {
|
||||
if (device.isConnected() || device.isConnecting()) {
|
||||
connectedDevice = device;
|
||||
}
|
||||
}
|
||||
|
@ -51,6 +51,10 @@ public class GBDevice {
|
||||
return state.ordinal() >= State.INITIALIZED.ordinal();
|
||||
}
|
||||
|
||||
public boolean isConnecting() {
|
||||
return state == State.CONNECTING;
|
||||
}
|
||||
|
||||
public State getState() {
|
||||
return state;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user