Merge pull request #1263 from Philoul/Fix/Insight_connectNewPumpMissing

Fix missing connectNewPump in Insight driver
This commit is contained in:
Milos Kozak 2022-02-07 15:03:49 +01:00 committed by GitHub
commit 056d42e81f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -30,6 +30,7 @@ import javax.inject.Inject;
import info.nightscout.androidaps.activities.NoSplashAppCompatActivity;
import info.nightscout.androidaps.insight.R;
import info.nightscout.androidaps.interfaces.PumpSync;
import info.nightscout.androidaps.plugins.pump.common.ble.BlePreCheck;
import info.nightscout.androidaps.plugins.pump.insight.connection_service.InsightConnectionService;
import info.nightscout.androidaps.plugins.pump.insight.descriptors.InsightState;
@ -39,6 +40,7 @@ public class InsightPairingActivity extends NoSplashAppCompatActivity implements
@Inject BlePreCheck blePreCheck;
@Inject Context context;
@Inject PumpSync pumpSync;
private boolean scanning;
private LinearLayout deviceSearchSection;
@ -64,6 +66,7 @@ public class InsightPairingActivity extends NoSplashAppCompatActivity implements
service.registerStateCallback(InsightPairingActivity.this);
service.registerExceptionCallback(InsightPairingActivity.this);
onStateChanged(service.getState());
pumpSync.connectNewPump();
}
}