commit
022df5e70d
18 changed files with 85 additions and 81 deletions
|
@ -151,7 +151,7 @@ var determine_basal = function determine_basal(glucose_status, currenttemp, iob_
|
|||
}
|
||||
}
|
||||
//cherry pick from oref upstream dev cb8e94990301277fb1016c778b4e9efa55a6edbc
|
||||
if (bg <= 10 || bg === 38 || noise >= 3 || minAgo > 12 || minAgo < -5 || ( bg > 60 && glucose_status.delta == 0 && glucose_status.short_avgdelta > -1 && glucose_status.short_avgdelta < 1 && glucose_status.long_avgdelta > -1 && glucose_status.long_avgdelta < 1 ) ) {
|
||||
if (bg <= 10 || bg === 38 || noise >= 3 || minAgo > 12 || minAgo < -5 || ( bg > 60 && glucose_status.delta == 0 && glucose_status.short_avgdelta > -1 && glucose_status.short_avgdelta < 1 && glucose_status.long_avgdelta > -1 && glucose_status.long_avgdelta < 1 ) && !isSaveCgmSource ) {
|
||||
if (currenttemp.rate > basal) { // high temp is running
|
||||
rT.reason += ". Replacing high temp basal of "+currenttemp.rate+" with neutral temp of "+basal;
|
||||
rT.deliverAt = deliverAt;
|
||||
|
|
|
@ -237,18 +237,21 @@ class LoopDialog : DaggerDialogFragment() {
|
|||
val profile = profileFunction.getProfile() ?: return true
|
||||
when (v.id) {
|
||||
R.id.overview_closeloop -> {
|
||||
aapsLogger.debug("USER ENTRY: CLOSED LOOP MODE")
|
||||
sp.putString(R.string.key_aps_mode, "closed")
|
||||
rxBus.send(EventPreferenceChange(resourceHelper.gs(R.string.closedloop)))
|
||||
return true
|
||||
}
|
||||
|
||||
R.id.overview_lgsloop -> {
|
||||
aapsLogger.debug("USER ENTRY: LGS LOOP MODE")
|
||||
sp.putString(R.string.key_aps_mode, "lgs")
|
||||
rxBus.send(EventPreferenceChange(resourceHelper.gs(R.string.lowglucosesuspend)))
|
||||
return true
|
||||
}
|
||||
|
||||
R.id.overview_openloop -> {
|
||||
aapsLogger.debug("USER ENTRY: OPEN LOOP MODE")
|
||||
sp.putString(R.string.key_aps_mode, "open")
|
||||
rxBus.send(EventPreferenceChange(resourceHelper.gs(R.string.lowglucosesuspend)))
|
||||
return true
|
||||
|
|
|
@ -19,7 +19,6 @@ import java.nio.charset.StandardCharsets;
|
|||
import javax.annotation.Nullable;
|
||||
import javax.inject.Inject;
|
||||
|
||||
import info.nightscout.androidaps.plugins.general.openhumans.OpenHumansUploader;
|
||||
import dagger.android.HasAndroidInjector;
|
||||
import info.nightscout.androidaps.Constants;
|
||||
import info.nightscout.androidaps.R;
|
||||
|
@ -28,13 +27,14 @@ import info.nightscout.androidaps.data.MealData;
|
|||
import info.nightscout.androidaps.data.Profile;
|
||||
import info.nightscout.androidaps.db.TemporaryBasal;
|
||||
import info.nightscout.androidaps.interfaces.ActivePluginProvider;
|
||||
import info.nightscout.androidaps.interfaces.ProfileFunction;
|
||||
import info.nightscout.androidaps.interfaces.PumpInterface;
|
||||
import info.nightscout.androidaps.logging.AAPSLogger;
|
||||
import info.nightscout.androidaps.logging.LTag;
|
||||
import info.nightscout.androidaps.plugins.aps.logger.LoggerCallback;
|
||||
import info.nightscout.androidaps.plugins.aps.loop.ScriptReader;
|
||||
import info.nightscout.androidaps.plugins.configBuilder.ConstraintChecker;
|
||||
import info.nightscout.androidaps.interfaces.ProfileFunction;
|
||||
import info.nightscout.androidaps.plugins.general.openhumans.OpenHumansUploader;
|
||||
import info.nightscout.androidaps.plugins.iob.iobCobCalculator.GlucoseStatus;
|
||||
import info.nightscout.androidaps.plugins.iob.iobCobCalculator.IobCobCalculatorPlugin;
|
||||
import info.nightscout.androidaps.plugins.treatments.TreatmentsPlugin;
|
||||
|
@ -73,10 +73,6 @@ public class DetermineBasalAdapterSMBJS {
|
|||
private String storedGlucoseStatus = null;
|
||||
private String storedProfile = null;
|
||||
private String storedMeal_data = null;
|
||||
private String storedAutosens_data = null;
|
||||
private String storedMicroBolusAllowed = null;
|
||||
private String storedSMBAlwaysAllowed = null;
|
||||
private String storedCurrentTime = null;
|
||||
|
||||
private String scriptDebug = "";
|
||||
|
||||
|
@ -102,13 +98,13 @@ public class DetermineBasalAdapterSMBJS {
|
|||
aapsLogger.debug(LTag.APS, "Profile: " + (storedProfile = mProfile.toString()));
|
||||
aapsLogger.debug(LTag.APS, "Meal data: " + (storedMeal_data = mMealData.toString()));
|
||||
if (mAutosensData != null)
|
||||
aapsLogger.debug(LTag.APS, "Autosens data: " + (storedAutosens_data = mAutosensData.toString()));
|
||||
aapsLogger.debug(LTag.APS, "Autosens data: " + mAutosensData.toString());
|
||||
else
|
||||
aapsLogger.debug(LTag.APS, "Autosens data: " + (storedAutosens_data = "undefined"));
|
||||
aapsLogger.debug(LTag.APS, "Autosens data: " + "undefined");
|
||||
aapsLogger.debug(LTag.APS, "Reservoir data: " + "undefined");
|
||||
aapsLogger.debug(LTag.APS, "MicroBolusAllowed: " + (storedMicroBolusAllowed = "" + mMicrobolusAllowed));
|
||||
aapsLogger.debug(LTag.APS, "SMBAlwaysAllowed: " + (storedSMBAlwaysAllowed = "" + mSMBAlwaysAllowed));
|
||||
aapsLogger.debug(LTag.APS, "CurrentTime: " + (storedCurrentTime = "" + mCurrentTime));
|
||||
aapsLogger.debug(LTag.APS, "MicroBolusAllowed: " + mMicrobolusAllowed);
|
||||
aapsLogger.debug(LTag.APS, "SMBAlwaysAllowed: " + mSMBAlwaysAllowed);
|
||||
aapsLogger.debug(LTag.APS, "CurrentTime: " + mCurrentTime);
|
||||
aapsLogger.debug(LTag.APS, "isSaveCgmSource: " + mIsSaveCgmSource);
|
||||
|
||||
|
||||
|
@ -151,9 +147,10 @@ public class DetermineBasalAdapterSMBJS {
|
|||
makeParam(mAutosensData, rhino, scope),
|
||||
makeParam(mMealData, rhino, scope),
|
||||
setTempBasalFunctionsObj,
|
||||
new Boolean(mMicrobolusAllowed),
|
||||
Boolean.valueOf(mMicrobolusAllowed),
|
||||
makeParam(null, rhino, scope), // reservoir data as undefined
|
||||
new Long(mCurrentTime)
|
||||
Long.valueOf(mCurrentTime),
|
||||
Boolean.valueOf(mIsSaveCgmSource)
|
||||
};
|
||||
|
||||
|
||||
|
@ -213,14 +210,6 @@ public class DetermineBasalAdapterSMBJS {
|
|||
return storedMeal_data;
|
||||
}
|
||||
|
||||
String getAutosensDataParam() {
|
||||
return storedAutosens_data;
|
||||
}
|
||||
|
||||
String getMicroBolusAllowedParam() {
|
||||
return storedMicroBolusAllowed;
|
||||
}
|
||||
|
||||
String getScriptDebug() {
|
||||
return scriptDebug;
|
||||
}
|
||||
|
@ -243,7 +232,6 @@ public class DetermineBasalAdapterSMBJS {
|
|||
boolean isSaveCgmSource
|
||||
) throws JSONException {
|
||||
|
||||
String units = profile.getUnits();
|
||||
PumpInterface pump = activePluginProvider.getActivePump();
|
||||
Double pumpbolusstep = pump.getPumpDescription().bolusStep;
|
||||
mProfile = new JSONObject();
|
||||
|
@ -267,8 +255,8 @@ public class DetermineBasalAdapterSMBJS {
|
|||
mProfile.put("low_temptarget_lowers_sensitivity", false);
|
||||
|
||||
|
||||
mProfile.put("sensitivity_raises_target", sp.getBoolean(R.string.key_sensitivity_raises_target,SMBDefaults.sensitivity_raises_target));
|
||||
mProfile.put("resistance_lowers_target", sp.getBoolean(R.string.key_resistance_lowers_target,SMBDefaults.resistance_lowers_target));
|
||||
mProfile.put("sensitivity_raises_target", sp.getBoolean(R.string.key_sensitivity_raises_target, SMBDefaults.sensitivity_raises_target));
|
||||
mProfile.put("resistance_lowers_target", sp.getBoolean(R.string.key_resistance_lowers_target, SMBDefaults.resistance_lowers_target));
|
||||
mProfile.put("adv_target_adjustments", SMBDefaults.adv_target_adjustments);
|
||||
mProfile.put("exercise_mode", SMBDefaults.exercise_mode);
|
||||
mProfile.put("half_basal_exercise_target", SMBDefaults.half_basal_exercise_target);
|
||||
|
@ -364,14 +352,12 @@ public class DetermineBasalAdapterSMBJS {
|
|||
|
||||
if (jsonObject == null) return Undefined.instance;
|
||||
|
||||
Object param = NativeJSON.parse(rhino, scope, jsonObject.toString(), (context, scriptable, scriptable1, objects) -> objects[1]);
|
||||
return param;
|
||||
return NativeJSON.parse(rhino, scope, jsonObject.toString(), (context, scriptable, scriptable1, objects) -> objects[1]);
|
||||
}
|
||||
|
||||
private Object makeParamArray(JSONArray jsonArray, Context rhino, Scriptable scope) {
|
||||
//Object param = NativeJSON.parse(rhino, scope, "{myarray: " + jsonArray.toString() + " }", new Callable() {
|
||||
Object param = NativeJSON.parse(rhino, scope, jsonArray.toString(), (context, scriptable, scriptable1, objects) -> objects[1]);
|
||||
return param;
|
||||
return NativeJSON.parse(rhino, scope, jsonArray.toString(), (context, scriptable, scriptable1, objects) -> objects[1]);
|
||||
}
|
||||
|
||||
private String readFile(String filename) throws IOException {
|
||||
|
|
|
@ -70,7 +70,7 @@ class EditEventDialog : DialogFragmentWithDate() {
|
|||
binding.okcancel.ok.visibility = (!event.readOnly).toVisibility()
|
||||
|
||||
binding.inputEventTitle.setText(event.title)
|
||||
binding.inputEventTitle.isFocusable = false
|
||||
binding.inputEventTitle.isFocusable = !event.readOnly
|
||||
binding.triggerDescription.text = event.trigger.friendlyDescription()
|
||||
|
||||
binding.editTrigger.visibility = (!event.readOnly).toVisibility()
|
||||
|
|
|
@ -289,12 +289,12 @@ class OverviewFragment : DaggerFragment(), View.OnClickListener, OnLongClickList
|
|||
R.id.overview_temptarget -> protectionCheck.queryProtection(activity, ProtectionCheck.Protection.BOLUS, UIRunnable { TempTargetDialog().show(childFragmentManager, "Overview") })
|
||||
|
||||
R.id.overview_activeprofile -> {
|
||||
val args = Bundle()
|
||||
args.putLong("time", DateUtil.now())
|
||||
args.putInt("mode", ProfileViewerDialog.Mode.RUNNING_PROFILE.ordinal)
|
||||
val pvd = ProfileViewerDialog()
|
||||
pvd.arguments = args
|
||||
pvd.show(childFragmentManager, "ProfileViewDialog")
|
||||
ProfileViewerDialog().also { pvd ->
|
||||
pvd.arguments = Bundle().also {
|
||||
it.putLong("time", DateUtil.now())
|
||||
it.putInt("mode", ProfileViewerDialog.Mode.RUNNING_PROFILE.ordinal)
|
||||
}
|
||||
}.show(childFragmentManager, "ProfileViewDialog")
|
||||
}
|
||||
|
||||
R.id.overview_cgmbutton -> {
|
||||
|
@ -329,24 +329,26 @@ class OverviewFragment : DaggerFragment(), View.OnClickListener, OnLongClickList
|
|||
val lastRun = loopPlugin.lastRun
|
||||
loopPlugin.invoke("Accept temp button", false)
|
||||
if (lastRun?.lastAPSRun != null && lastRun.constraintsProcessed?.isChangeRequested == true) {
|
||||
OKDialog.showConfirmation(activity, resourceHelper.gs(R.string.tempbasal_label), lastRun.constraintsProcessed?.toSpanned()
|
||||
?: "".toSpanned(), {
|
||||
aapsLogger.debug("USER ENTRY: ACCEPT TEMP BASAL")
|
||||
overview_accepttempbutton?.visibility = View.GONE
|
||||
(context?.getSystemService(Context.NOTIFICATION_SERVICE) as NotificationManager).cancel(Constants.notificationID)
|
||||
actionStringHandler.handleInitiate("cancelChangeRequest")
|
||||
loopPlugin.acceptChangeRequest()
|
||||
protectionCheck.queryProtection(activity, ProtectionCheck.Protection.BOLUS, UIRunnable {
|
||||
OKDialog.showConfirmation(activity, resourceHelper.gs(R.string.tempbasal_label), lastRun.constraintsProcessed?.toSpanned()
|
||||
?: "".toSpanned(), {
|
||||
aapsLogger.debug("USER ENTRY: ACCEPT TEMP BASAL")
|
||||
overview_accepttempbutton?.visibility = View.GONE
|
||||
(context?.getSystemService(Context.NOTIFICATION_SERVICE) as NotificationManager).cancel(Constants.notificationID)
|
||||
actionStringHandler.handleInitiate("cancelChangeRequest")
|
||||
loopPlugin.acceptChangeRequest()
|
||||
})
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
R.id.overview_apsmode -> {
|
||||
val args = Bundle()
|
||||
args.putInt("showOkCancel", 1) // 1-> true
|
||||
val pvd = LoopDialog()
|
||||
pvd.arguments = args
|
||||
pvd.show(childFragmentManager, "Overview")
|
||||
protectionCheck.queryProtection(activity, ProtectionCheck.Protection.BOLUS, UIRunnable {
|
||||
LoopDialog().also { dialog ->
|
||||
dialog.arguments = Bundle().also { it.putInt("showOkCancel", 1) }
|
||||
}.show(childFragmentManager, "Overview")
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -374,11 +376,13 @@ class OverviewFragment : DaggerFragment(), View.OnClickListener, OnLongClickList
|
|||
}
|
||||
|
||||
R.id.overview_apsmode -> {
|
||||
val args = Bundle()
|
||||
args.putInt("showOkCancel", 0) // 0-> false
|
||||
val pvd = LoopDialog()
|
||||
pvd.arguments = args
|
||||
pvd.show(childFragmentManager, "Overview")
|
||||
activity?.let { activity ->
|
||||
protectionCheck.queryProtection(activity, ProtectionCheck.Protection.BOLUS, UIRunnable {
|
||||
LoopDialog().also { dialog ->
|
||||
dialog.arguments = Bundle().also { it.putInt("showOkCancel", 0) }
|
||||
}.show(childFragmentManager, "Overview")
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
R.id.overview_temptarget -> v.performClick()
|
||||
|
|
|
@ -162,18 +162,20 @@
|
|||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:layout_marginBottom="-4dp"
|
||||
android:visibility="gone"
|
||||
app:srcCompat="@drawable/ic_loop_closed" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/overview_apsmode_text"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:gravity="center_horizontal"
|
||||
android:paddingTop="3dp"
|
||||
android:paddingBottom="3dp"
|
||||
android:text="Open Loop"
|
||||
android:textAppearance="@style/TextAppearance.AppCompat.Medium"
|
||||
android:textStyle="bold" />
|
||||
android:textStyle="bold"
|
||||
android:visibility="gone" />
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
|
@ -183,6 +185,7 @@
|
|||
android:layout_marginTop="5dp"
|
||||
android:gravity="center_horizontal"
|
||||
android:orientation="vertical"
|
||||
android:visibility="gone"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/overview_bg"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toEndOf="@id/overview_apsmode_llayout"
|
||||
|
|
|
@ -1,14 +1,12 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<string name="alert_r7_description"><![CDATA[Amount: <b>%1$d%%</b>\nDuration: <b>%2$s h</b>]]></string>
|
||||
|
||||
<string name="alert_w31_description"><![CDATA[Cartridge content: <b>%1$s U</b>]]></string>
|
||||
<string name="alert_w32_description">Change battery.</string>
|
||||
<string name="alert_w33_description">Set time/date.</string>
|
||||
<string name="alert_w34_description">Contact Accu-Chek support.</string>
|
||||
<string name="alert_w36_description"><![CDATA[Amount: <b>%1$d%%</b><br/>Duration: <b>%2$s h</b>]]></string>
|
||||
<string name="alert_w38_description"><![CDATA[Programmed: <b>%1$s U</b><br/>Delivered: <b>%2$s U</b>]]></string>
|
||||
|
||||
<string name="alert_m20_description">Insert cartridge.</string>
|
||||
<string name="alert_m21_description">Change cartridge.</string>
|
||||
<string name="alert_m22_description">Change battery.</string>
|
||||
|
@ -20,7 +18,6 @@
|
|||
<string name="alert_m28_description">Check pump status.</string>
|
||||
<string name="alert_m29_description">Set battery type.</string>
|
||||
<string name="alert_m30_description">Set cartridge type.</string>
|
||||
|
||||
<string name="alert_e6_description">Change battery and cartridge.</string>
|
||||
<string name="alert_e10_description">Change cartridge.</string>
|
||||
<string name="alert_e13_description">Change language.</string>
|
||||
|
|
|
@ -1425,7 +1425,7 @@
|
|||
<string name="bolusadvisormessage">You have high glycemia. Instead of eating now it\'s recommended to wait for better glycemia. Do you want to do a correction bolus now and remind you when it\'s time to eat? In this case no carbs will be recorded and you must use wizard again when we remind you.</string>
|
||||
<string name="key_usebolusadvisor" translatable="false">use_bolus_advisor</string>
|
||||
<string name="enablebolusadvisor">Enable bolus advisor</string>
|
||||
<string name="enablebolusadvisor_summary">Use reminder to start eating instead of wizard during high glycemia</string>
|
||||
<string name="enablebolusadvisor_summary">Use reminder to start eating later instead of wizard result during high glycemia ("pre-bolus")</string>
|
||||
<string name="time_to_eat">Time to eat!\nRun Bolus wizard and do calculation again.</string>
|
||||
<string name="timetoeat">Time to eat</string>
|
||||
|
||||
|
|
|
@ -2,10 +2,10 @@
|
|||
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:validate="http://schemas.android.com/apk/res-auto">
|
||||
|
||||
|
||||
<PreferenceCategory
|
||||
app:initialExpandedChildrenCount="0"
|
||||
android:title="@string/openapssmb">
|
||||
android:title="@string/openapssmb"
|
||||
app:initialExpandedChildrenCount="0">
|
||||
|
||||
<info.nightscout.androidaps.utils.textValidator.ValidatingEditTextPreference
|
||||
android:defaultValue="1"
|
||||
|
@ -88,10 +88,15 @@
|
|||
|
||||
<info.nightscout.androidaps.utils.textValidator.ValidatingEditTextPreference
|
||||
android:defaultValue="30"
|
||||
android:digits="0123456789"
|
||||
android:entries="@array/smbMaxMinutes"
|
||||
android:entryValues="@array/smbMaxMinutes"
|
||||
android:inputType="number"
|
||||
android:key="@string/key_smbmaxminutes"
|
||||
android:title="@string/smbmaxminutes_summary" />
|
||||
android:title="@string/smbmaxminutes_summary"
|
||||
validate:maxNumber="120"
|
||||
validate:minNumber="15"
|
||||
validate:testType="numericRange" />
|
||||
|
||||
<info.nightscout.androidaps.utils.textValidator.ValidatingEditTextPreference
|
||||
android:defaultValue="30"
|
||||
|
@ -119,14 +124,12 @@
|
|||
android:defaultValue="true"
|
||||
android:key="@string/key_sensitivity_raises_target"
|
||||
android:summary="@string/sensitivity_raises_target_summary"
|
||||
android:title="@string/sensitivity_raises_target_title"
|
||||
/>
|
||||
android:title="@string/sensitivity_raises_target_title" />
|
||||
<SwitchPreference
|
||||
android:defaultValue="false"
|
||||
android:key="@string/key_resistance_lowers_target"
|
||||
android:summary="@string/resistance_lowers_target_summary"
|
||||
android:title="@string/resistance_lowers_target_title"
|
||||
/>
|
||||
android:title="@string/resistance_lowers_target_title" />
|
||||
<!-- TODO AS-FIX -->
|
||||
<SwitchPreference
|
||||
android:defaultValue="false"
|
||||
|
@ -142,21 +145,21 @@
|
|||
android:key="@string/key_low_temptarget_lowers_sensitivity"
|
||||
android:summary="@string/low_temptarget_lowers_sensitivity_summary"
|
||||
android:title="@string/low_temptarget_lowers_sensitivity_title" />
|
||||
|
||||
|
||||
<info.nightscout.androidaps.utils.textValidator.ValidatingEditTextPreference
|
||||
android:key="@string/key_carbsReqThreshold"
|
||||
android:title="@string/carbsReqThreshold"
|
||||
android:summary="@string/carbsReqThreshold_summary"
|
||||
android:defaultValue="1"
|
||||
android:dialogMessage="@string/carbsReqThreshold_summary"
|
||||
android:digits="0123456789"
|
||||
android:inputType="number"
|
||||
android:key="@string/key_carbsReqThreshold"
|
||||
android:maxLines="20"
|
||||
android:selectAllOnFocus="true"
|
||||
android:singleLine="true"
|
||||
android:summary="@string/carbsReqThreshold_summary"
|
||||
android:title="@string/carbsReqThreshold"
|
||||
validate:maxNumber="10"
|
||||
validate:minNumber="1"
|
||||
validate:testType="numericRange"/>
|
||||
validate:testType="numericRange" />
|
||||
|
||||
<androidx.preference.PreferenceScreen
|
||||
android:key="absorption_smb_advanced"
|
||||
|
|
|
@ -277,6 +277,7 @@ class DanaRSService : DaggerService() {
|
|||
danaPump.bolusStopped = true
|
||||
danaPump.bolusStopForced = true
|
||||
aapsLogger.debug(LTag.PUMPCOMM, "Communication stopped")
|
||||
bleComm.disconnect("Communication stopped")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -102,10 +102,12 @@ class OmnipodOverviewFragment : DaggerFragment() {
|
|||
omnipod_overview_button_pod_management.setOnClickListener {
|
||||
if (omnipodPumpPlugin.rileyLinkService?.verifyConfiguration() == true) {
|
||||
activity?.let { activity ->
|
||||
protectionCheck.queryProtection(
|
||||
activity, ProtectionCheck.Protection.PREFERENCES,
|
||||
UIRunnable(Runnable { startActivity(Intent(context, PodManagementActivity::class.java)) })
|
||||
)
|
||||
context?.let { context ->
|
||||
protectionCheck.queryProtection(
|
||||
activity, ProtectionCheck.Protection.PREFERENCES,
|
||||
UIRunnable { startActivity(Intent(context, PodManagementActivity::class.java)) }
|
||||
)
|
||||
}
|
||||
}
|
||||
} else {
|
||||
displayNotConfiguredDialog()
|
||||
|
@ -514,10 +516,10 @@ class OmnipodOverviewFragment : DaggerFragment() {
|
|||
|
||||
private fun displayNotConfiguredDialog() {
|
||||
context?.let {
|
||||
UIRunnable(Runnable {
|
||||
UIRunnable {
|
||||
OKDialog.show(it, resourceHelper.gs(R.string.omnipod_warning),
|
||||
resourceHelper.gs(R.string.omnipod_error_operation_not_possible_no_configuration), null)
|
||||
}).run()
|
||||
}.run()
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -534,9 +536,9 @@ class OmnipodOverviewFragment : DaggerFragment() {
|
|||
|
||||
private fun displayOkDialog(title: String, message: String) {
|
||||
context?.let {
|
||||
UIRunnable(Runnable {
|
||||
UIRunnable {
|
||||
OKDialog.show(it, title, message, null)
|
||||
}).run()
|
||||
}.run()
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -65,6 +65,11 @@ public class InitializePumpManagerTask extends ServiceTask {
|
|||
lastGoodFrequency = rileyLinkServiceData.lastGoodFrequency;
|
||||
}
|
||||
|
||||
/* FIXME this can apparently crash:
|
||||
Fatal Exception: java.lang.ClassCastException
|
||||
info.nightscout.androidaps.plugins.pump.virtual.VirtualPumpPlugin
|
||||
cannot be cast to info.nightscout.androidaps.plugins.pump.common.hw.rileylink.defs.RileyLinkPumpDevice
|
||||
*/
|
||||
RileyLinkCommunicationManager<?> rileyLinkCommunicationManager = ((RileyLinkPumpDevice) activePlugin.getActivePump()).getRileyLinkService().getDeviceCommunicationManager();
|
||||
|
||||
if (activePlugin.getActivePump().manufacturer() == ManufacturerType.Medtronic) {
|
||||
|
|
BIN
wear/src/main/res/drawable/digitalstyle_bg_minimal_rect.png
Normal file
BIN
wear/src/main/res/drawable/digitalstyle_bg_minimal_rect.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 354 B |
BIN
wear/src/main/res/drawable/digitalstyle_bg_minimal_round.png
Normal file
BIN
wear/src/main/res/drawable/digitalstyle_bg_minimal_round.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 354 B |
BIN
wear/src/main/res/drawable/digitalstyle_bg_none_rect.png
Normal file
BIN
wear/src/main/res/drawable/digitalstyle_bg_none_rect.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 137 B |
BIN
wear/src/main/res/drawable/digitalstyle_bg_none_round.png
Normal file
BIN
wear/src/main/res/drawable/digitalstyle_bg_none_round.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 137 B |
BIN
wear/src/main/res/drawable/digitalstyle_bg_shape_rect.png
Normal file
BIN
wear/src/main/res/drawable/digitalstyle_bg_shape_rect.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 42 KiB |
BIN
wear/src/main/res/drawable/digitalstyle_bg_shape_round.png
Normal file
BIN
wear/src/main/res/drawable/digitalstyle_bg_shape_round.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 69 KiB |
Loading…
Reference in a new issue