Compat for SR 1.6.0
This commit is contained in:
parent
73d7d98354
commit
60d3cde0d3
2 changed files with 3 additions and 3 deletions
Binary file not shown.
|
@ -62,7 +62,7 @@ public class Connector {
|
||||||
private int serviceReconnects = 0;
|
private int serviceReconnects = 0;
|
||||||
private StatusCallback statusCallback = new StatusCallback() {
|
private StatusCallback statusCallback = new StatusCallback() {
|
||||||
@Override
|
@Override
|
||||||
public synchronized void onStatusChange(Status status) {
|
public synchronized void onStatusChange(Status status, long statusTime, long waitTime) {
|
||||||
|
|
||||||
if ((status != lastStatus) || (Helpers.msSince(lastStatusTime) > 2000)) {
|
if ((status != lastStatus) || (Helpers.msSince(lastStatusTime) > 2000)) {
|
||||||
log("Status change: " + status);
|
log("Status change: " + status);
|
||||||
|
@ -94,7 +94,7 @@ public class Connector {
|
||||||
serviceConnector.connect();
|
serviceConnector.connect();
|
||||||
} else {
|
} else {
|
||||||
log("PROTOCOL VERSION MISMATCH! local: " + COMPATIBILITY_VERSION + " remote: " + remoteVersion);
|
log("PROTOCOL VERSION MISMATCH! local: " + COMPATIBILITY_VERSION + " remote: " + remoteVersion);
|
||||||
statusCallback.onStatusChange(Status.INCOMPATIBLE);
|
statusCallback.onStatusChange(Status.INCOMPATIBLE, 0, 0);
|
||||||
compatabilityMessage = gs(R.string.insight_incompatible_compantion_app_we_need_version) + " " + getLocalVersion();
|
compatabilityMessage = gs(R.string.insight_incompatible_compantion_app_we_need_version) + " " + getLocalVersion();
|
||||||
serviceConnector.disconnectFromService();
|
serviceConnector.disconnectFromService();
|
||||||
|
|
||||||
|
@ -102,7 +102,7 @@ public class Connector {
|
||||||
} catch (NullPointerException e) {
|
} catch (NullPointerException e) {
|
||||||
log("ERROR: null pointer when trying to connect to pump");
|
log("ERROR: null pointer when trying to connect to pump");
|
||||||
}
|
}
|
||||||
statusCallback.onStatusChange(safeGetStatus());
|
statusCallback.onStatusChange(safeGetStatus(), 0, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
Loading…
Reference in a new issue