Merge branch 'dev' into eopatch2

This commit is contained in:
Milos Kozak 2022-02-11 09:30:41 +01:00 committed by GitHub
commit febe64b3c6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
169 changed files with 2330 additions and 747 deletions

View file

@ -20,7 +20,10 @@ jobs:
# The next step will run the unit tests
- android/run-tests:
test-command: ./gradlew -Pcoverage -PfirebaseDisable testFullDebugUnitTest jacocoTestFullDebugUnitTestReport
test-command: ./gradlew testFullDebugUnitTest
- android/run-tests:
test-command: ./gradlew jacocoAllDebugReport
# Then start the emulator and run the Instrumentation tests!
# - android/start-emulator-and-run-tests:
@ -33,35 +36,7 @@ jobs:
# command: |
# ./gradlew assembleRelease
- codecov/upload:
file: './app/build/jacoco/jacoco.xml'
- codecov/upload:
file: './automation/build/jacoco/jacoco.xml'
- codecov/upload:
file: './combo/build/jacoco/jacoco.xml'
- codecov/upload:
file: './core/build/jacoco/jacoco.xml'
- codecov/upload:
file: './dana/build/jacoco/jacoco.xml'
- codecov/upload:
file: './danar/build/jacoco/jacoco.xml'
- codecov/upload:
file: './danars/build/jacoco/jacoco.xml'
- codecov/upload:
file: './database/build/jacoco/jacoco.xml'
- codecov/upload:
file: './insight/build/jacoco/jacoco.xml'
- codecov/upload:
file: './medtronic/build/jacoco/jacoco.xml'
- codecov/upload:
file: './omnipod-common/build/jacoco/jacoco.xml'
- codecov/upload:
file: './omnipod-dash/build/jacoco/jacoco.xml'
- codecov/upload:
file: './omnipod-eros/build/jacoco/jacoco.xml'
- codecov/upload:
file: './rileylink/build/jacoco/jacoco.xml'
- codecov/upload:
file: './wear/build/jacoco/jacoco.xml'
file: './build/reports/jacoco/jacocoAllDebugReport/jacocoAllDebugReport.xml'
workflows:
# Below is the definition of your workflow.

View file

@ -1,15 +1,19 @@
# AndroidAPS
* Check the wiki: https://androidaps.readthedocs.io
* Everyone whos been looping with AndroidAPS needs to fill out the form after 3 days of looping https://docs.google.com/forms/d/14KcMjlINPMJHVt28MDRupa4sz4DDIooI4SrW0P3HSN8/viewform?c=0&w=1
[![Support Server](https://img.shields.io/discord/629952586895851530.svg?label=Discord&logo=Discord&colorB=7289da&style=for-the-badge)](https://discord.gg/4fQUWHZ4Mw)
[![Build status](https://travis-ci.org/nightscout/AndroidAPS.svg?branch=master)](https://travis-ci.org/nightscout/AndroidAPS)
[![CircleCI](https://circleci.com/gh/nightscout/AndroidAPS/tree/master.svg?style=svg)](https://circleci.com/gh/nightscout/AndroidAPS/tree/master)
[![Crowdin](https://d322cqt584bo4o.cloudfront.net/androidaps/localized.svg)](https://translations.androidaps.org/project/androidaps)
[![Documentation Status](https://readthedocs.org/projects/androidaps/badge/?version=latest)](https://androidaps.readthedocs.io/en/latest/?badge=latest)
[![codecov](https://codecov.io/gh/MilosKozak/AndroidAPS/branch/master/graph/badge.svg)](https://codecov.io/gh/MilosKozak/AndroidAPS)
dev: [![codecov](https://codecov.io/gh/MilosKozak/AndroidAPS/branch/dev/graph/badge.svg)](https://codecov.io/gh/MilosKozak/AndroidAPS)
[![codecov](https://codecov.io/gh/nightscout/AndroidAPS/branch/master/graph/badge.svg)](https://codecov.io/gh/MilosKozak/AndroidAPS)
DEV:
[![CircleCI](https://circleci.com/gh/nightscout/AndroidAPS/tree/dev.svg?style=svg)](https://circleci.com/gh/nightscout/AndroidAPS/tree/dev)
[![codecov](https://codecov.io/gh/nightscout/AndroidAPS/branch/dev/graph/badge.svg)](https://codecov.io/gh/MilosKozak/AndroidAPS)
![BTC](https://bitit.io/assets/coins/icon-btc-1e5a37bc0eb730ac83130d7aa859052bd4b53ac3f86f99966627801f7b0410be.svg) 3KawK8aQe48478s6fxJ8Ms6VTWkwjgr9f2
<img src="https://cdn.iconscout.com/icon/free/png-256/bitcoin-384-920569.png" srcset="https://cdn.iconscout.com/icon/free/png-512/bitcoin-384-920569.png 2x" alt="Bitcoin Icon" width="100">
3KawK8aQe48478s6fxJ8Ms6VTWkwjgr9f2

View file

@ -109,7 +109,7 @@ android {
defaultConfig {
multiDexEnabled true
versionCode 1500
version "3.0.0.1"
version "3.0.0.1-dev"
buildConfigField "String", "VERSION", '"' + version + '"'
buildConfigField "String", "BUILDVERSION", '"' + generateGitBuild() + '-' + generateDate() + '"'
buildConfigField "String", "REMOTE", '"' + generateGitRemote() + '"'

View file

@ -69,10 +69,10 @@ var determine_basal = function determine_basal(glucose_status, currenttemp, iob_
if (bg < 39) { //Dexcom is in ??? mode or calibrating
rT.reason = "CGM is calibrating or in ??? state";
if (basal <= currenttemp.rate * 1.2) { // high temp is running
rT.reason += "; setting current basal of " + basal + " as temp";
rT.reason += "; setting current basal of " + round(basal, 2) + " as temp";
return tempBasalFunctions.setTempBasal(basal, 30, profile, rT, currenttemp);
} else { //do nothing.
rT.reason += ", temp " + currenttemp.rate + " <~ current basal " + basal + "U/hr";
rT.reason += ", temp " + currenttemp.rate + " <~ current basal " + round(basal, 2) + "U/hr";
return rT;
}
}
@ -291,7 +291,7 @@ var determine_basal = function determine_basal(glucose_status, currenttemp, iob_
rT.COB=meal_data.mealCOB;
rT.IOB=iob_data.iob;
rT.reason="COB: " + meal_data.mealCOB + ", Dev: " + deviation + ", BGI: " + bgi + ", ISF: " + convert_bg(sens, profile) + ", Target: " + convert_bg(target_bg, profile) + "; ";
rT.reason="COB: " + round(meal_data.mealCOB, 1) + ", Dev: " + deviation + ", BGI: " + bgi + ", ISF: " + convert_bg(sens, profile) + ", Target: " + convert_bg(target_bg, profile) + "; ";
if (typeof autosens_data !== 'undefined' && profile.autosens_adjust_targets && autosens_data.ratio != 1)
rT.reason += "Autosens: " + autosens_data.ratio + "; ";
if (bg < threshold) { // low glucose suspend mode: BG is < ~80
@ -306,10 +306,10 @@ var determine_basal = function determine_basal(glucose_status, currenttemp, iob_
rT.reason += ", min delta " + minDelta.toFixed(2) + ">0";
}
if (currenttemp.duration > 15 && (round_basal(basal, profile) === round_basal(currenttemp.rate, profile))) {
rT.reason += ", temp " + currenttemp.rate + " ~ req " + basal + "U/hr";
rT.reason += ", temp " + currenttemp.rate + " ~ req " + round(basal, 2) + "U/hr";
return rT;
} else {
rT.reason += "; setting current basal of " + basal + " as temp";
rT.reason += "; setting current basal of " + round(basal, 2) + " as temp";
return tempBasalFunctions.setTempBasal(basal, 30, profile, rT, currenttemp);
}
}
@ -327,7 +327,7 @@ var determine_basal = function determine_basal(glucose_status, currenttemp, iob_
rT.reason += ", temp " + currenttemp.rate + " ~ req " + basal + "U/hr";
return rT;
} else {
rT.reason += "; setting current basal of " + basal + " as temp";
rT.reason += "; setting current basal of " + round(basal, 2) + " as temp";
return tempBasalFunctions.setTempBasal(basal, 30, profile, rT, currenttemp);
}
}
@ -338,10 +338,10 @@ var determine_basal = function determine_basal(glucose_status, currenttemp, iob_
rT.reason += ", bolus snooze: eventual BG range " + convert_bg(eventualBG, profile) + "-" + convert_bg(snoozeBG, profile);
//console.error(currenttemp, basal );
if (currenttemp.duration > 15 && (round_basal(basal, profile) === round_basal(currenttemp.rate, profile))) {
rT.reason += ", temp " + currenttemp.rate + " ~ req " + basal + "U/hr";
rT.reason += ", temp " + currenttemp.rate + " ~ req " + round(basal, 2) + "U/hr";
return rT;
} else {
rT.reason += "; setting current basal of " + basal + " as temp";
rT.reason += "; setting current basal of " + round(basal, 2) + " as temp";
return tempBasalFunctions.setTempBasal(basal, 30, profile, rT, currenttemp);
}
} else {
@ -363,7 +363,7 @@ var determine_basal = function determine_basal(glucose_status, currenttemp, iob_
// if required temp < existing temp basal
var insulinScheduled = currenttemp.duration * (currenttemp.rate - basal) / 60;
if (insulinScheduled < insulinReq - basal*0.3) { // if current temp would deliver a lot (30% of basal) less than the required insulin, raise the rate
rT.reason += ", "+currenttemp.duration + "m@" + (currenttemp.rate - basal).toFixed(3) + " = " + insulinScheduled.toFixed(3) + " < req " + insulinReq + "-" + basal*0.3;
rT.reason += ", "+currenttemp.duration + "m@" + (currenttemp.rate - basal).toFixed(3) + " = " + insulinScheduled.toFixed(3) + " < req " + insulinReq + "-" + (basal*0.3).toFixed(2);
return tempBasalFunctions.setTempBasal(rate, 30, profile, rT, currenttemp);
}
if (typeof currenttemp.rate !== 'undefined' && (currenttemp.duration > 5 && rate >= currenttemp.rate * 0.8)) {
@ -405,10 +405,10 @@ var determine_basal = function determine_basal(glucose_status, currenttemp, iob_
rT.reason += "Eventual BG " + convert_bg(eventualBG, profile) + " > " + convert_bg(min_bg, profile) + " but Min. Delta " + minDelta.toFixed(2) + " < Exp. Delta " + expectedDelta;
}
if (currenttemp.duration > 15 && (round_basal(basal, profile) === round_basal(currenttemp.rate, profile))) {
rT.reason += ", temp " + currenttemp.rate + " ~ req " + basal + "U/hr";
rT.reason += ", temp " + currenttemp.rate + " ~ req " + round(basal, 2) + "U/hr";
return rT;
} else {
rT.reason += "; setting current basal of " + basal + " as temp";
rT.reason += "; setting current basal of " + round(basal, 2) + " as temp";
return tempBasalFunctions.setTempBasal(basal, 30, profile, rT, currenttemp);
}
}
@ -422,10 +422,10 @@ var determine_basal = function determine_basal(glucose_status, currenttemp, iob_
rT.reason += convert_bg(eventualBG, profile)+"-"+convert_bg(snoozeBG, profile)+" in range: no temp required";
if (currenttemp.duration > 15 && (round_basal(basal, profile) === round_basal(currenttemp.rate, profile))) {
rT.reason += ", temp " + currenttemp.rate + " ~ req " + basal + "U/hr";
rT.reason += ", temp " + currenttemp.rate + " ~ req " + round(basal, 2) + "U/hr";
return rT;
} else {
rT.reason += "; setting current basal of " + basal + " as temp";
rT.reason += "; setting current basal of " + round(basal, 2) + " as temp";
return tempBasalFunctions.setTempBasal(basal, 30, profile, rT, currenttemp);
}
}
@ -439,10 +439,10 @@ var determine_basal = function determine_basal(glucose_status, currenttemp, iob_
if (basaliob > max_iob) {
rT.reason += "basaliob " + round(basaliob,2) + " > max_iob " + max_iob;
if (currenttemp.duration > 15 && (round_basal(basal, profile) === round_basal(currenttemp.rate, profile))) {
rT.reason += ", temp " + currenttemp.rate + " ~ req " + basal + "U/hr";
rT.reason += ", temp " + currenttemp.rate + " ~ req " + round(basal, 2) + "U/hr";
return rT;
} else {
rT.reason += "; setting current basal of " + basal + " as temp";
rT.reason += "; setting current basal of " + round(basal, 2) + " as temp";
return tempBasalFunctions.setTempBasal(basal, 30, profile, rT, currenttemp);
}
} else { // otherwise, calculate 30m high-temp required to get projected BG down to target

View file

@ -169,7 +169,7 @@ var determine_basal = function determine_basal(glucose_status, currenttemp, iob_
return rT;
//return tempBasalFunctions.setTempBasal(0, 30, profile, rT, currenttemp);
} else { //do nothing.
rT.reason += ". Temp " + currenttemp.rate + " <= current basal " + basal + "U/hr; doing nothing. ";
rT.reason += ". Temp " + currenttemp.rate + " <= current basal " + round(basal, 2) + "U/hr; doing nothing. ";
return rT;
}
}
@ -920,10 +920,10 @@ var determine_basal = function determine_basal(glucose_status, currenttemp, iob_
rT.reason += ", but Min. Delta " + minDelta.toFixed(2) + " > Exp. Delta " + convert_bg(expectedDelta, profile);
}
if (currenttemp.duration > 15 && (round_basal(basal, profile) === round_basal(currenttemp.rate, profile))) {
rT.reason += ", temp " + currenttemp.rate + " ~ req " + basal + "U/hr. ";
rT.reason += ", temp " + currenttemp.rate + " ~ req " + round(basal, 2) + "U/hr. ";
return rT;
} else {
rT.reason += "; setting current basal of " + basal + " as temp. ";
rT.reason += "; setting current basal of " + round(basal, 2) + " as temp. ";
return tempBasalFunctions.setTempBasal(basal, 30, profile, rT, currenttemp);
}
}
@ -992,10 +992,10 @@ var determine_basal = function determine_basal(glucose_status, currenttemp, iob_
rT.reason += "Eventual BG " + convert_bg(eventualBG, profile) + " > " + convert_bg(min_bg, profile) + " but Min. Delta " + minDelta.toFixed(2) + " < Exp. Delta " + convert_bg(expectedDelta, profile);
}
if (currenttemp.duration > 15 && (round_basal(basal, profile) === round_basal(currenttemp.rate, profile))) {
rT.reason += ", temp " + currenttemp.rate + " ~ req " + basal + "U/hr. ";
rT.reason += ", temp " + currenttemp.rate + " ~ req " + round(basal, 2) + "U/hr. ";
return rT;
} else {
rT.reason += "; setting current basal of " + basal + " as temp. ";
rT.reason += "; setting current basal of " + round(basal, 2) + " as temp. ";
return tempBasalFunctions.setTempBasal(basal, 30, profile, rT, currenttemp);
}
}
@ -1006,10 +1006,10 @@ var determine_basal = function determine_basal(glucose_status, currenttemp, iob_
if (! (microBolusAllowed && enableSMB )) {
rT.reason += convert_bg(eventualBG, profile)+"-"+convert_bg(minPredBG, profile)+" in range: no temp required";
if (currenttemp.duration > 15 && (round_basal(basal, profile) === round_basal(currenttemp.rate, profile))) {
rT.reason += ", temp " + currenttemp.rate + " ~ req " + basal + "U/hr. ";
rT.reason += ", temp " + currenttemp.rate + " ~ req " + round(basal, 2) + "U/hr. ";
return rT;
} else {
rT.reason += "; setting current basal of " + basal + " as temp. ";
rT.reason += "; setting current basal of " + round(basal, 2) + " as temp. ";
return tempBasalFunctions.setTempBasal(basal, 30, profile, rT, currenttemp);
}
}
@ -1023,10 +1023,10 @@ var determine_basal = function determine_basal(glucose_status, currenttemp, iob_
if (iob_data.iob > max_iob) {
rT.reason += "IOB " + round(iob_data.iob,2) + " > max_iob " + max_iob;
if (currenttemp.duration > 15 && (round_basal(basal, profile) === round_basal(currenttemp.rate, profile))) {
rT.reason += ", temp " + currenttemp.rate + " ~ req " + basal + "U/hr. ";
rT.reason += ", temp " + currenttemp.rate + " ~ req " + round(basal, 2) + "U/hr. ";
return rT;
} else {
rT.reason += "; setting current basal of " + basal + " as temp. ";
rT.reason += "; setting current basal of " + round(basal, 2) + " as temp. ";
return tempBasalFunctions.setTempBasal(basal, 30, profile, rT, currenttemp);
}
} else { // otherwise, calculate 30m high-temp required to get projected BG down to target

View file

@ -271,6 +271,8 @@ class TreatmentsBolusCarbsFragment : DaggerFragment() {
_binding = null
}
private fun timestamp(ml: MealLink): Long = ml.bolusCalculatorResult?.let { it.timestamp } ?: ml.bolus?.let { it.timestamp } ?: ml.carbs?.let { it.timestamp } ?: 0L
inner class RecyclerViewAdapter internal constructor(var mealLinks: List<MealLink>) : RecyclerView.Adapter<RecyclerViewAdapter.MealLinkLoadedViewHolder>() {
override fun onCreateViewHolder(viewGroup: ViewGroup, viewType: Int): MealLinkLoadedViewHolder =
@ -280,16 +282,20 @@ class TreatmentsBolusCarbsFragment : DaggerFragment() {
val profile = profileFunction.getProfile() ?: return
val ml = mealLinks[position]
val sameDayPrevious = position > 0 && dateUtil.isSameDay(timestamp(ml), timestamp(mealLinks[position - 1]))
holder.binding.date.visibility = sameDayPrevious.not().toVisibility()
holder.binding.date.text = dateUtil.dateString(timestamp(ml))
// Metadata
holder.binding.metadataLayout.visibility = (ml.bolusCalculatorResult != null && (ml.bolusCalculatorResult.isValid || binding.showInvalidated.isChecked)).toVisibility()
ml.bolusCalculatorResult?.let { bolusCalculatorResult ->
holder.binding.date.text = dateUtil.dateAndTimeString(bolusCalculatorResult.timestamp)
holder.binding.calcTime.text = dateUtil.timeString(bolusCalculatorResult.timestamp)
}
// Bolus
holder.binding.bolusLayout.visibility = (ml.bolus != null && (ml.bolus.isValid || binding.showInvalidated.isChecked)).toVisibility()
ml.bolus?.let { bolus ->
holder.binding.bolusDate.text = dateUtil.timeString(bolus.timestamp)
holder.binding.bolusTime.text = dateUtil.timeString(bolus.timestamp)
holder.binding.insulin.text = rh.gs(R.string.formatinsulinunits, bolus.amount)
holder.binding.bolusNs.visibility = (bolus.interfaceIDs.nightscoutId != null).toVisibility()
holder.binding.bolusPump.visibility = (bolus.interfaceIDs.pumpId != null).toVisibility()
@ -317,7 +323,7 @@ class TreatmentsBolusCarbsFragment : DaggerFragment() {
// Carbs
holder.binding.carbsLayout.visibility = (ml.carbs != null && (ml.carbs.isValid || binding.showInvalidated.isChecked)).toVisibility()
ml.carbs?.let { carbs ->
holder.binding.carbsDate.text = dateUtil.timeString(carbs.timestamp)
holder.binding.carbsTime.text = dateUtil.timeString(carbs.timestamp)
holder.binding.carbs.text = rh.gs(R.string.format_carbs, carbs.amount.toInt())
holder.binding.carbsDuration.text = if (carbs.duration > 0) rh.gs(R.string.format_mins, T.msecs(carbs.duration).mins().toInt()) else ""
holder.binding.carbsNs.visibility = (carbs.interfaceIDs.nightscoutId != null).toVisibility()
@ -330,6 +336,8 @@ class TreatmentsBolusCarbsFragment : DaggerFragment() {
holder.binding.bolusRemove.tag = ml
holder.binding.carbsRemove.tag = ml
holder.binding.calculation.tag = ml
val nextTimestamp = if (mealLinks.size != position + 1) timestamp(mealLinks[position + 1]) else 0L
holder.binding.delimiter.visibility = dateUtil.isSameDay(timestamp(ml), nextTimestamp).toVisibility()
}
override fun getItemCount(): Int {

View file

@ -152,7 +152,7 @@ class TreatmentsCareportalFragment : DaggerFragment() {
_binding = null
}
inner class RecyclerViewAdapter internal constructor(private var list: List<TherapyEvent>) : RecyclerView.Adapter<TherapyEventsViewHolder>() {
inner class RecyclerViewAdapter internal constructor(private var therapyList: List<TherapyEvent>) : RecyclerView.Adapter<TherapyEventsViewHolder>() {
override fun onCreateViewHolder(viewGroup: ViewGroup, viewType: Int): TherapyEventsViewHolder {
val v = LayoutInflater.from(viewGroup.context).inflate(R.layout.treatments_careportal_item, viewGroup, false)
@ -160,18 +160,23 @@ class TreatmentsCareportalFragment : DaggerFragment() {
}
override fun onBindViewHolder(holder: TherapyEventsViewHolder, position: Int) {
val therapyEvent = list[position]
val therapyEvent = therapyList[position]
holder.binding.ns.visibility = (therapyEvent.interfaceIDs.nightscoutId != null).toVisibility()
holder.binding.invalid.visibility = therapyEvent.isValid.not().toVisibility()
holder.binding.date.text = dateUtil.dateAndTimeString(therapyEvent.timestamp)
val sameDayPrevious = position > 0 && dateUtil.isSameDay(therapyEvent.timestamp, therapyList[position - 1].timestamp)
holder.binding.date.visibility = sameDayPrevious.not().toVisibility()
holder.binding.date.text = dateUtil.dateString(therapyEvent.timestamp)
holder.binding.time.text = dateUtil.timeString(therapyEvent.timestamp)
holder.binding.duration.text = if (therapyEvent.duration == 0L) "" else dateUtil.niceTimeScalar(therapyEvent.duration, rh)
holder.binding.note.text = therapyEvent.note
holder.binding.type.text = translator.translate(therapyEvent.type)
holder.binding.remove.tag = therapyEvent
val nextTimestamp = if (therapyList.size != position + 1) therapyList[position + 1].timestamp else 0L
holder.binding.delimiter.visibility = dateUtil.isSameDay(therapyEvent.timestamp, nextTimestamp).toVisibility()
}
override fun getItemCount(): Int {
return list.size
return therapyList.size
}
inner class TherapyEventsViewHolder(view: View) : RecyclerView.ViewHolder(view) {

View file

@ -125,13 +125,16 @@ class TreatmentsExtendedBolusesFragment : DaggerFragment() {
holder.binding.ns.visibility = (extendedBolus.interfaceIDs.nightscoutId != null).toVisibility()
holder.binding.ph.visibility = (extendedBolus.interfaceIDs.pumpId != null).toVisibility()
holder.binding.invalid.visibility = extendedBolus.isValid.not().toVisibility()
val sameDayPrevious = position > 0 && dateUtil.isSameDay(extendedBolus.timestamp, extendedBolusList[position-1].timestamp)
holder.binding.date.visibility = sameDayPrevious.not().toVisibility()
holder.binding.date.text = dateUtil.dateString(extendedBolus.timestamp)
@SuppressLint("SetTextI18n")
if (extendedBolus.isInProgress(dateUtil)) {
holder.binding.date.text = dateUtil.dateAndTimeString(extendedBolus.timestamp)
holder.binding.date.setTextColor(rh.gc(R.color.colorActive))
holder.binding.time.text = dateUtil.timeString(extendedBolus.timestamp)
holder.binding.time.setTextColor(rh.gc(R.color.colorActive))
} else {
holder.binding.date.text = dateUtil.dateAndTimeString(extendedBolus.timestamp) + " - " + dateUtil.timeString(extendedBolus.end)
holder.binding.date.setTextColor(holder.binding.insulin.currentTextColor)
holder.binding.time.text = dateUtil.timeRangeString(extendedBolus.timestamp, extendedBolus.end)
holder.binding.time.setTextColor(holder.binding.insulin.currentTextColor)
}
val profile = profileFunction.getProfile(extendedBolus.timestamp) ?: return
holder.binding.duration.text = rh.gs(R.string.format_mins, T.msecs(extendedBolus.duration).mins())
@ -141,6 +144,8 @@ class TreatmentsExtendedBolusesFragment : DaggerFragment() {
holder.binding.ratio.text = rh.gs(R.string.pump_basebasalrate, extendedBolus.rate)
if (iob.iob != 0.0) holder.binding.iob.setTextColor(rh.gc(R.color.colorActive)) else holder.binding.iob.setTextColor(holder.binding.insulin.currentTextColor)
holder.binding.remove.tag = extendedBolus
val nextTimestamp = if (extendedBolusList.size != position + 1) extendedBolusList[position + 1].timestamp else 0L
holder.binding.delimiter.visibility = dateUtil.isSameDay(extendedBolus.timestamp, nextTimestamp).toVisibility()
}
override fun getItemCount(): Int = extendedBolusList.size

View file

@ -181,7 +181,10 @@ class TreatmentsProfileSwitchFragment : DaggerFragment() {
val profileSwitch = profileSwitchList[position]
holder.binding.ph.visibility = (profileSwitch is ProfileSealed.EPS).toVisibility()
holder.binding.ns.visibility = (profileSwitch.interfaceIDs_backing?.nightscoutId != null).toVisibility()
holder.binding.date.text = dateUtil.dateAndTimeString(profileSwitch.timestamp)
val sameDayPrevious = position > 0 && dateUtil.isSameDay(profileSwitch.timestamp, profileSwitchList[position - 1].timestamp)
holder.binding.date.visibility = sameDayPrevious.not().toVisibility()
holder.binding.date.text = dateUtil.dateString(profileSwitch.timestamp)
holder.binding.time.text = dateUtil.timeString(profileSwitch.timestamp)
holder.binding.duration.text = rh.gs(R.string.format_mins, T.msecs(profileSwitch.duration ?: 0L).mins())
holder.binding.name.text = if (profileSwitch is ProfileSealed.PS) profileSwitch.value.getCustomizedName() else if (profileSwitch is ProfileSealed.EPS) profileSwitch.value.originalCustomizedName else ""
if (profileSwitch.isInProgress(dateUtil)) holder.binding.date.setTextColor(rh.gc(R.color.colorActive))
@ -196,6 +199,8 @@ class TreatmentsProfileSwitchFragment : DaggerFragment() {
holder.binding.clone.visibility = (profileSwitch is ProfileSealed.PS).toVisibility()
holder.binding.spacer.visibility = (profileSwitch is ProfileSealed.PS).toVisibility()
holder.binding.root.setBackgroundColor(rh.gc(if (profileSwitch is ProfileSealed.PS) R.color.defaultbackground else R.color.list_delimiter))
val nextTimestamp = if (profileSwitchList.size != position + 1) profileSwitchList[position + 1].timestamp else 0L
holder.binding.delimiter.visibility = dateUtil.isSameDay(profileSwitch.timestamp, nextTimestamp).toVisibility()
}
override fun getItemCount(): Int {

View file

@ -164,18 +164,23 @@ class TreatmentsTempTargetFragment : DaggerFragment() {
holder.binding.ns.visibility = (tempTarget.interfaceIDs.nightscoutId != null).toVisibility()
holder.binding.invalid.visibility = tempTarget.isValid.not().toVisibility()
holder.binding.remove.visibility = tempTarget.isValid.toVisibility()
holder.binding.date.text = dateUtil.dateAndTimeString(tempTarget.timestamp) + " - " + dateUtil.timeString(tempTarget.end)
val sameDayPrevious = position > 0 && dateUtil.isSameDay(tempTarget.timestamp, tempTargetList[position-1].timestamp)
holder.binding.date.visibility = sameDayPrevious.not().toVisibility()
holder.binding.date.text = dateUtil.dateString(tempTarget.timestamp)
holder.binding.time.text = dateUtil.timeRangeString(tempTarget.timestamp, tempTarget.end)
holder.binding.duration.text = rh.gs(R.string.format_mins, T.msecs(tempTarget.duration).mins())
holder.binding.low.text = tempTarget.lowValueToUnitsToString(units)
holder.binding.high.text = tempTarget.highValueToUnitsToString(units)
holder.binding.reason.text = translator.translate(tempTarget.reason)
holder.binding.date.setTextColor(
holder.binding.time.setTextColor(
when {
tempTarget.id == currentlyActiveTarget?.id -> rh.gc(R.color.colorActive)
tempTarget.timestamp > dateUtil.now() -> rh.gc(R.color.colorScheduled)
else -> holder.binding.reasonColon.currentTextColor
})
holder.binding.remove.tag = tempTarget
val nextTimestamp = if (tempTargetList.size != position + 1) tempTargetList[position + 1].timestamp else 0L
holder.binding.delimiter.visibility = dateUtil.isSameDay(tempTarget.timestamp, nextTimestamp).toVisibility()
}
override fun getItemCount(): Int = tempTargetList.size

View file

@ -15,7 +15,6 @@ import info.nightscout.androidaps.database.AppRepository
import info.nightscout.androidaps.database.ValueWrapper
import info.nightscout.androidaps.database.entities.ExtendedBolus
import info.nightscout.androidaps.database.entities.TemporaryBasal
import info.nightscout.androidaps.database.entities.UserEntry.*
import info.nightscout.androidaps.database.entities.UserEntry.Action
import info.nightscout.androidaps.database.entities.UserEntry.Sources
import info.nightscout.androidaps.database.entities.ValueWithUnit
@ -165,12 +164,15 @@ class TreatmentsTemporaryBasalsFragment : DaggerFragment() {
holder.binding.ns.visibility = (tempBasal.interfaceIDs.nightscoutId != null).toVisibility()
holder.binding.invalid.visibility = tempBasal.isValid.not().toVisibility()
holder.binding.ph.visibility = (tempBasal.interfaceIDs.pumpId != null).toVisibility()
val sameDayPrevious = position > 0 && dateUtil.isSameDay(tempBasal.timestamp, tempBasalList[position-1].timestamp)
holder.binding.date.visibility = sameDayPrevious.not().toVisibility()
holder.binding.date.text = dateUtil.dateString(tempBasal.timestamp)
if (tempBasal.isInProgress) {
holder.binding.date.text = dateUtil.dateAndTimeString(tempBasal.timestamp)
holder.binding.date.setTextColor(rh.gc(R.color.colorActive))
holder.binding.time.text = dateUtil.timeString(tempBasal.timestamp)
holder.binding.time.setTextColor(rh.gc(R.color.colorActive))
} else {
holder.binding.date.text = dateUtil.dateAndTimeRangeString(tempBasal.timestamp, tempBasal.end)
holder.binding.date.setTextColor(holder.binding.duration.currentTextColor)
holder.binding.time.text = dateUtil.timeRangeString(tempBasal.timestamp, tempBasal.end)
holder.binding.time.setTextColor(holder.binding.duration.currentTextColor)
}
holder.binding.duration.text = rh.gs(R.string.format_mins, T.msecs(tempBasal.duration).mins())
if (tempBasal.isAbsolute) holder.binding.rate.text = rh.gs(R.string.pump_basebasalrate, tempBasal.rate)
@ -186,6 +188,9 @@ class TreatmentsTemporaryBasalsFragment : DaggerFragment() {
holder.binding.superBolusFlag.visibility = (tempBasal.type == TemporaryBasal.Type.SUPERBOLUS).toVisibility()
if (abs(iob.basaliob) > 0.01) holder.binding.iob.setTextColor(rh.gc(R.color.colorActive)) else holder.binding.iob.setTextColor(holder.binding.duration.currentTextColor)
holder.binding.remove.tag = tempBasal
val nextTimestamp = if (tempBasalList.size != position + 1) tempBasalList[position + 1].timestamp else 0L
holder.binding.delimiter.visibility = dateUtil.isSameDay(tempBasal.timestamp, nextTimestamp).toVisibility()
}
override fun getItemCount(): Int = tempBasalList.size

View file

@ -20,6 +20,7 @@ import info.nightscout.androidaps.interfaces.ProfileFunction
import info.nightscout.androidaps.logging.UserEntryLogger
import info.nightscout.androidaps.plugins.bus.RxBus
import info.nightscout.androidaps.events.EventTreatmentUpdateGui
import info.nightscout.androidaps.extensions.toVisibility
import info.nightscout.androidaps.utils.DateUtil
import info.nightscout.androidaps.utils.FabricPrivacy
import info.nightscout.androidaps.utils.T
@ -131,14 +132,19 @@ class TreatmentsUserEntryFragment : DaggerFragment() {
override fun onBindViewHolder(holder: UserEntryViewHolder, position: Int) {
val current = entries[position]
holder.binding.date.text = dateUtil.dateAndTimeAndSecondsString(current.timestamp)
val sameDayPrevious = position > 0 && dateUtil.isSameDay(current.timestamp, entries[position-1].timestamp)
holder.binding.date.visibility = sameDayPrevious.not().toVisibility()
holder.binding.date.text = dateUtil.dateString(current.timestamp)
holder.binding.time.text = dateUtil.timeStringWithSeconds(current.timestamp)
holder.binding.action.text = userEntryPresentationHelper.actionToColoredString(current.action)
holder.binding.s.text = current.note
holder.binding.s.visibility = if (current.note != "") View.VISIBLE else View.GONE
holder.binding.notes.text = current.note
holder.binding.notes.visibility = if (current.note != "") View.VISIBLE else View.GONE
holder.binding.iconSource.setImageResource(userEntryPresentationHelper.iconId(current.source))
holder.binding.iconSource.visibility = View.VISIBLE
holder.binding.values.text = userEntryPresentationHelper.listToPresentationString(current.values)
holder.binding.values.visibility = if (holder.binding.values.text != "") View.VISIBLE else View.GONE
val nextTimestamp = if (entries.size != position + 1) entries[position + 1].timestamp else 0L
holder.binding.delimiter.visibility = dateUtil.isSameDay(current.timestamp, nextTimestamp).toVisibility()
}
inner class UserEntryViewHolder(itemView: View) : RecyclerView.ViewHolder(itemView) {

View file

@ -179,9 +179,17 @@ class TreatmentDialog : DialogFragmentWithDate() {
}
}
})
} else
} else {
uel.log(action, Sources.TreatmentDialog,
ValueWithUnit.Gram(carbsAfterConstraints).takeIf { carbs != 0 })
ValueWithUnit.Gram(carbsAfterConstraints).takeIf { carbsAfterConstraints != 0 })
if (detailedBolusInfo.carbs > 0) {
disposable += repository.runTransactionForResult(detailedBolusInfo.insertCarbsTransaction())
.subscribe(
{ result -> result.inserted.forEach { aapsLogger.debug(LTag.DATABASE, "Inserted carbs $it") } },
{ aapsLogger.error(LTag.DATABASE, "Error while saving carbs", it) }
)
}
}
}
})
}

View file

@ -4,11 +4,7 @@ import android.content.Context
import android.os.Bundle
import android.text.Editable
import android.text.TextWatcher
import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
import android.view.Window
import android.view.WindowManager
import android.view.*
import android.widget.AdapterView
import android.widget.AdapterView.OnItemSelectedListener
import android.widget.ArrayAdapter
@ -136,33 +132,36 @@ class WizardDialog : DaggerDialogFragment() {
val maxCorrection = constraintChecker.getMaxBolusAllowed().value()
bolusStep = activePlugin.activePump.pumpDescription.bolusStep
if (profileFunction.getUnits() == GlucoseUnit.MGDL)
binding.bgInput.setParams(savedInstanceState?.getDouble("bg_input")
?: 0.0, 0.0, 500.0, 1.0, DecimalFormat("0"), false, binding.ok, timeTextWatcher)
else
binding.bgInput.setParams(savedInstanceState?.getDouble("bg_input")
?: 0.0, 0.0, 30.0, 0.1, DecimalFormat("0.0"), false, binding.ok, textWatcher)
if (profileFunction.getUnits() == GlucoseUnit.MGDL) {
binding.bgInput.setParams(
savedInstanceState?.getDouble("bg_input")
?: 0.0, 0.0, 500.0, 1.0, DecimalFormat("0"), false, binding.okcancel.ok, timeTextWatcher)
} else {
binding.bgInput.setParams(
savedInstanceState?.getDouble("bg_input")
?: 0.0, 0.0, 30.0, 0.1, DecimalFormat("0.0"), false, binding.okcancel.ok, textWatcher)
}
binding.carbsInput.setParams(savedInstanceState?.getDouble("carbs_input")
?: 0.0, 0.0, maxCarbs.toDouble(), 1.0, DecimalFormat("0"), false, binding.ok, textWatcher)
?: 0.0, 0.0, maxCarbs.toDouble(), 1.0, DecimalFormat("0"), false, binding.okcancel.ok, textWatcher)
if (correctionPercent) {
calculatedPercentage = sp.getInt(R.string.key_boluswizard_percentage, 100).toDouble()
binding.correctionInput.setParams(calculatedPercentage, 10.0, 200.0, 1.0, DecimalFormat("0"), false, binding.ok, textWatcher)
binding.correctionInput.setParams(calculatedPercentage, 10.0, 200.0, 1.0, DecimalFormat("0"), false, binding.okcancel.ok, textWatcher)
binding.correctionInput.value = calculatedPercentage
binding.correctionUnit.text = "%"
} else {
binding.correctionInput.setParams(
savedInstanceState?.getDouble("correction_input")
?: 0.0, -maxCorrection, maxCorrection, bolusStep, DecimalFormatter.pumpSupportedBolusFormat(activePlugin.activePump), false, binding.ok, textWatcher)
?: 0.0, -maxCorrection, maxCorrection, bolusStep, DecimalFormatter.pumpSupportedBolusFormat(activePlugin.activePump), false, binding.okcancel.ok, textWatcher)
binding.correctionUnit.text = rh.gs(R.string.insulin_unit_shortname)
}
binding.carbTimeInput.setParams(savedInstanceState?.getDouble("carb_time_input")
?: 0.0, -60.0, 60.0, 5.0, DecimalFormat("0"), false, binding.ok, timeTextWatcher)
?: 0.0, -60.0, 60.0, 5.0, DecimalFormat("0"), false, binding.okcancel.ok, timeTextWatcher)
initDialog()
calculatedPercentage = sp.getInt(R.string.key_boluswizard_percentage, 100).toDouble()
binding.percentUsed.text = rh.gs(R.string.format_percent, sp.getInt(R.string.key_boluswizard_percentage, 100))
// ok button
binding.ok.setOnClickListener {
binding.okcancel.ok.setOnClickListener {
if (okClicked) {
aapsLogger.debug(LTag.UI, "guarding: ok already clicked")
} else {
@ -175,12 +174,12 @@ class WizardDialog : DaggerDialogFragment() {
}
dismiss()
}
binding.bgEnabledIcon.setOnClickListener { binding.bgCheckbox.isChecked = !binding.bgCheckbox.isChecked }
binding.trendEnabledIcon.setOnClickListener { binding.bgTrendCheckbox.isChecked = !binding.bgTrendCheckbox.isChecked }
binding.cobEnabledIcon.setOnClickListener { binding.cobCheckbox.isChecked = !binding.cobCheckbox.isChecked; processCobCheckBox(); }
binding.iobEnabledIcon.setOnClickListener { if (!binding.cobCheckbox.isChecked) binding.iobCheckbox.isChecked = !binding.iobCheckbox.isChecked }
binding.bgCheckboxIcon.setOnClickListener { binding.bgCheckbox.isChecked = !binding.bgCheckbox.isChecked }
binding.trendCheckboxIcon.setOnClickListener { binding.bgTrendCheckbox.isChecked = !binding.bgTrendCheckbox.isChecked }
binding.cobCheckboxIcon.setOnClickListener { binding.cobCheckbox.isChecked = !binding.cobCheckbox.isChecked; processCobCheckBox(); }
binding.iobCheckboxIcon.setOnClickListener { if (!binding.cobCheckbox.isChecked) binding.iobCheckbox.isChecked = !binding.iobCheckbox.isChecked }
// cancel button
binding.cancel.setOnClickListener {
binding.okcancel.cancel.setOnClickListener {
aapsLogger.debug(LTag.APS, "Dialog canceled: ${this.javaClass.name}")
dismiss()
}
@ -212,11 +211,17 @@ class WizardDialog : DaggerDialogFragment() {
sp.putBoolean(rh.gs(R.string.key_wizard_correction_percent), isChecked)
binding.correctionUnit.text = if (isChecked) "%" else rh.gs(R.string.insulin_unit_shortname)
correctionPercent = binding.correctionPercent.isChecked
if (correctionPercent)
binding.correctionInput.setParams(calculatedPercentage, 10.0, 200.0, 1.0, DecimalFormat("0"), false, binding.ok, textWatcher)
else
binding.correctionInput.setParams(savedInstanceState?.getDouble("correction_input")
?: 0.0, -maxCorrection, maxCorrection, bolusStep, DecimalFormatter.pumpSupportedBolusFormat(activePlugin.activePump), false, binding.ok, textWatcher)
if (correctionPercent) {
binding.correctionInput.setParams(calculatedPercentage, 10.0, 200.0, 1.0, DecimalFormat("0"), false, binding.okcancel.ok, textWatcher)
binding.correctionInput.customContentDescription = rh.gs(R.string.a11_correction_percentage)
} else {
binding.correctionInput.setParams(
savedInstanceState?.getDouble("correction_input")
?: 0.0, -maxCorrection, maxCorrection, bolusStep, DecimalFormatter.pumpSupportedBolusFormat(activePlugin.activePump), false, binding.okcancel.ok, textWatcher
)
binding.correctionInput.customContentDescription = rh.gs(R.string.a11_correction_units)
}
binding.correctionInput.updateA11yDescription()
binding.correctionInput.value = if (correctionPercent) calculatedPercentage else Round.roundTo(calculatedCorrection, bolusStep)
}
}
@ -224,12 +229,12 @@ class WizardDialog : DaggerDialogFragment() {
binding.profile.onItemSelectedListener = object : OnItemSelectedListener {
override fun onNothingSelected(parent: AdapterView<*>?) {
ToastUtils.showToastInUiThread(ctx, rh.gs(R.string.noprofileset))
binding.ok.visibility = View.GONE
binding.okcancel.ok.visibility = View.GONE
}
override fun onItemSelected(parent: AdapterView<*>?, view: View?, position: Int, id: Long) {
calculateInsulin()
binding.ok.visibility = View.VISIBLE
binding.okcancel.ok.visibility = View.VISIBLE
}
}
// bus
@ -241,6 +246,14 @@ class WizardDialog : DaggerDialogFragment() {
}, fabricPrivacy::logException)
)
setA11yLabels()
}
private fun setA11yLabels() {
binding.bgInput.editText?.id?.let { binding.bgInputLabel.labelFor = it }
binding.carbsInput.editText?.id?.let { binding.carbsInputLabel.labelFor = it }
binding.correctionInput.editText?.id?.let { binding.correctionInputLabel.labelFor = it }
binding.carbTimeInput.editText?.id?.let { binding.carbTimeInputLabel.labelFor = it }
}
override fun onDestroyView() {
@ -268,14 +281,14 @@ class WizardDialog : DaggerDialogFragment() {
}
private fun processEnabledIcons() {
binding.bgEnabledIcon.alpha = if (binding.bgCheckbox.isChecked) 1.0f else 0.2f
binding.trendEnabledIcon.alpha = if (binding.bgTrendCheckbox.isChecked) 1.0f else 0.2f
binding.iobEnabledIcon.alpha = if (binding.iobCheckbox.isChecked) 1.0f else 0.2f
binding.cobEnabledIcon.alpha = if (binding.cobCheckbox.isChecked) 1.0f else 0.2f
binding.bgEnabledIcon.visibility = binding.calculationCheckbox.isChecked.not().toVisibility()
binding.trendEnabledIcon.visibility = binding.calculationCheckbox.isChecked.not().toVisibility()
binding.iobEnabledIcon.visibility = binding.calculationCheckbox.isChecked.not().toVisibility()
binding.cobEnabledIcon.visibility = binding.calculationCheckbox.isChecked.not().toVisibility()
binding.bgCheckboxIcon.alpha = if (binding.bgCheckbox.isChecked) 1.0f else 0.2f
binding.trendCheckboxIcon.alpha = if (binding.bgTrendCheckbox.isChecked) 1.0f else 0.2f
binding.iobCheckboxIcon.alpha = if (binding.iobCheckbox.isChecked) 1.0f else 0.2f
binding.cobCheckboxIcon.alpha = if (binding.cobCheckbox.isChecked) 1.0f else 0.2f
binding.bgCheckboxIcon.visibility = binding.calculationCheckbox.isChecked.not().toVisibility()
binding.trendCheckboxIcon.visibility = binding.calculationCheckbox.isChecked.not().toVisibility()
binding.iobCheckboxIcon.visibility = binding.calculationCheckbox.isChecked.not().toVisibility()
binding.cobCheckboxIcon.visibility = binding.calculationCheckbox.isChecked.not().toVisibility()
}
private fun saveCheckedStates() {
@ -442,10 +455,10 @@ class WizardDialog : DaggerDialogFragment() {
val insulinText = if (wizard.calculatedTotalInsulin > 0.0) rh.gs(R.string.formatinsulinunits, wizard.calculatedTotalInsulin).formatColor(rh, R.color.bolus) else ""
val carbsText = if (carbsAfterConstraint > 0.0) rh.gs(R.string.format_carbs, carbsAfterConstraint).formatColor(rh, R.color.carbs) else ""
binding.total.text = HtmlHelper.fromHtml(rh.gs(R.string.result_insulin_carbs, insulinText, carbsText))
binding.ok.visibility = View.VISIBLE
binding.okcancel.ok.visibility = View.VISIBLE
} else {
binding.total.text = HtmlHelper.fromHtml(rh.gs(R.string.missing_carbs, wizard.carbsEquivalent.toInt()).formatColor(rh, R.color.carbs))
binding.ok.visibility = View.INVISIBLE
binding.okcancel.ok.visibility = View.INVISIBLE
}
binding.percentUsed.text = rh.gs(R.string.format_percent, wizard.percentageCorrection)
calculatedPercentage = wizard.calculatedPercentage

View file

@ -110,7 +110,7 @@ class OpenAPSAMAFragment : DaggerFragment() {
binding.profile.text = jsonFormatter.format(determineBasalAdapterAMAJS.profileParam)
binding.mealdata.text = jsonFormatter.format(determineBasalAdapterAMAJS.mealDataParam)
binding.scriptdebugdata.text = determineBasalAdapterAMAJS.scriptDebug
binding.scriptdebugdata.text = determineBasalAdapterAMAJS.scriptDebug.replace("\\s+".toRegex(), " ")
}
if (openAPSAMAPlugin.lastAPSRun != 0L) {
binding.lastrun.text = dateUtil.dateAndTimeString(openAPSAMAPlugin.lastAPSRun)

View file

@ -110,7 +110,7 @@ class OpenAPSSMBFragment : DaggerFragment() {
binding.profile.text = jsonFormatter.format(determineBasalAdapterSMBJS.profileParam)
binding.mealdata.text = jsonFormatter.format(determineBasalAdapterSMBJS.mealDataParam)
binding.scriptdebugdata.text = determineBasalAdapterSMBJS.scriptDebug
binding.scriptdebugdata.text = determineBasalAdapterSMBJS.scriptDebug.replace("\\s+".toRegex(), " ")
openAPSSMBPlugin.lastAPSResult?.inputConstraints?.let {
binding.constraints.text = it.getReasons(aapsLogger)
}

View file

@ -107,6 +107,7 @@ class ActionsFragment : DaggerFragment() {
private var sensorLevelLabel: TextView? = null
private var insulinLevelLabel: TextView? = null
private var pbLevelLabel: TextView? = null
private var cannulaOrPatch: TextView? = null
override fun onCreateView(
inflater: LayoutInflater, container: ViewGroup?,
@ -153,6 +154,7 @@ class ActionsFragment : DaggerFragment() {
sensorLevelLabel = view.findViewById(R.id.sensor_level_label)
insulinLevelLabel = view.findViewById(R.id.insulin_level_label)
pbLevelLabel = view.findViewById(R.id.pb_level_label)
cannulaOrPatch = view.findViewById(R.id.cannula_or_patch)
profileSwitch?.setOnClickListener {
ProfileSwitchDialog().show(childFragmentManager, "ProfileSwitchDialog")
@ -319,6 +321,10 @@ class ActionsFragment : DaggerFragment() {
tempTarget?.visibility = (profile != null && !loop.isDisconnected).toVisibility()
tddStats?.visibility = pump.pumpDescription.supportsTDDs.toVisibility()
cannulaOrPatch?.text = if (pump.pumpDescription.isPatchPump) rh.gs(R.string.patch_pump) else rh.gs(R.string.cannula)
val imageResource = if (pump.pumpDescription.isPatchPump) R.drawable.ic_patch_pump_outline else R.drawable.ic_cp_age_cannula
cannulaOrPatch?.setCompoundDrawablesWithIntrinsicBounds(imageResource, 0, 0, 0)
if (!config.NSCLIENT) {
statusLightHandler.updateStatusLights(cannulaAge, insulinAge, reservoirLevel, sensorAge, sensorLevel, pbAge, batteryLevel)
sensorLevelLabel?.text = if (activeBgSource.sensorBatteryLevel == -1) "" else rh.gs(R.string.careportal_level_label)

View file

@ -823,7 +823,15 @@ class OverviewFragment : DaggerFragment(), View.OnClickListener, OnLongClickList
fun updateTime(from: String) {
binding.infoLayout.time.text = dateUtil.timeString(dateUtil.now())
// Status lights
binding.statusLightsLayout.statusLights.visibility = (sp.getBoolean(R.string.key_show_statuslights, true) || config.NSCLIENT).toVisibility()
val isPatchPump = activePlugin.activePump.pumpDescription.isPatchPump
binding.statusLightsLayout.apply {
cannulaOrPatch.setImageResource(if (isPatchPump) R.drawable.ic_patch_pump_outline else R.drawable.ic_cp_age_cannula)
cannulaOrPatch.contentDescription = rh.gs(if (isPatchPump) R.string.statuslights_patch_pump_age else R.string.statuslights_cannula_age)
cannulaOrPatch.scaleX = if (isPatchPump) 1.4f else 2f
cannulaOrPatch.scaleY = cannulaOrPatch.scaleX
insulinAge.visibility = isPatchPump.not().toVisibility()
statusLights.visibility = (sp.getBoolean(R.string.key_show_statuslights, true) || config.NSCLIENT).toVisibility()
}
statusLightHandler.updateStatusLights(
binding.statusLightsLayout.cannulaAge,
binding.statusLightsLayout.insulinAge,

View file

@ -40,12 +40,7 @@ class StatusLightHandler @Inject constructor(
val pump = activePlugin.activePump
val bgSource = activePlugin.activeBgSource
handleAge(careportal_cannula_age, TherapyEvent.Type.CANNULA_CHANGE, R.string.key_statuslights_cage_warning, 48.0, R.string.key_statuslights_cage_critical, 72.0)
if (pump.model() == PumpType.OMNIPOD_EROS || pump.model() == PumpType.OMNIPOD_DASH) {
careportal_insulin_age?.visibility = View.GONE
} else {
careportal_insulin_age?.visibility = View.VISIBLE
handleAge(careportal_insulin_age, TherapyEvent.Type.INSULIN_CHANGE, R.string.key_statuslights_iage_warning, 72.0, R.string.key_statuslights_iage_critical, 144.0)
}
handleAge(careportal_insulin_age, TherapyEvent.Type.INSULIN_CHANGE, R.string.key_statuslights_iage_warning, 72.0, R.string.key_statuslights_iage_critical, 144.0)
handleAge(careportal_sensor_age, TherapyEvent.Type.SENSOR_CHANGE, R.string.key_statuslights_sage_warning, 216.0, R.string.key_statuslights_sage_critical, 240.0)
if (pump.pumpDescription.isBatteryReplaceable || (pump is OmnipodErosPumpPlugin && pump.isUseRileyLinkBatteryLevel && pump.isBatteryChangeLoggingEnabled)) {
handleAge(careportal_pb_age, TherapyEvent.Type.PUMP_BATTERY_CHANGE, R.string.key_statuslights_bage_warning, 216.0, R.string.key_statuslights_bage_critical, 240.0)

View file

@ -18,10 +18,11 @@ class ActivityGraph : GraphView {
constructor(context: Context, attrs: AttributeSet?) : super(context, attrs)
fun show(insulin: Insulin) {
fun show(insulin: Insulin, diaSample: Double? = null) {
removeAllSeries()
val dia = diaSample ?: insulin.dia
mSecondScale = null
val hours = floor(insulin.dia + 1).toLong()
val hours = floor(dia + 1).toLong()
val bolus = Bolus(
timestamp = 0,
amount = 1.0,
@ -31,7 +32,7 @@ class ActivityGraph : GraphView {
val iobArray: MutableList<DataPoint> = ArrayList()
var time: Long = 0
while (time <= T.hours(hours).msecs()) {
val iob = insulin.iobCalcForTreatment(bolus, time, insulin.dia)
val iob = insulin.iobCalcForTreatment(bolus, time, dia)
activityArray.add(DataPoint(T.msecs(time).mins().toDouble(), iob.activityContrib))
iobArray.add(DataPoint(T.msecs(time).mins().toDouble(), iob.iobContrib))
time += T.mins(5).msecs()

View file

@ -3,6 +3,7 @@ package info.nightscout.androidaps.plugins.profile.local
import android.os.Bundle
import android.text.Editable
import android.text.TextWatcher
import android.util.Log
import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
@ -20,7 +21,6 @@ import info.nightscout.androidaps.dialogs.ProfileSwitchDialog
import info.nightscout.androidaps.interfaces.ActivePlugin
import info.nightscout.androidaps.interfaces.GlucoseUnit
import info.nightscout.androidaps.interfaces.Profile
import info.nightscout.shared.logging.AAPSLogger
import info.nightscout.androidaps.logging.UserEntryLogger
import info.nightscout.androidaps.plugins.bus.RxBus
import info.nightscout.androidaps.plugins.profile.local.events.EventLocalProfileChanged
@ -31,8 +31,10 @@ import info.nightscout.androidaps.utils.rx.AapsSchedulers
import info.nightscout.androidaps.utils.ui.SpinnerHelper
import info.nightscout.androidaps.utils.ui.TimeListEdit
import info.nightscout.shared.SafeParse
import info.nightscout.shared.logging.AAPSLogger
import io.reactivex.disposables.CompositeDisposable
import io.reactivex.rxkotlin.plusAssign
import java.math.RoundingMode
import java.text.DecimalFormat
import javax.inject.Inject
@ -61,6 +63,8 @@ class LocalProfileFragment : DaggerFragment() {
binding.basalGraph.show(ProfileSealed.Pure(it))
binding.icGraph.show(ProfileSealed.Pure(it))
binding.isfGraph.show(ProfileSealed.Pure(it))
binding.targetGraph.show(ProfileSealed.Pure(it))
binding.insulinGraph.show(activePlugin.activeInsulin, SafeParse.stringToDouble(binding.dia.text))
}
}
@ -130,14 +134,22 @@ class LocalProfileFragment : DaggerFragment() {
binding.name.addTextChangedListener(textWatch)
binding.dia.setParams(currentProfile.dia, hardLimits.minDia(), hardLimits.maxDia(), 0.1, DecimalFormat("0.0"), false, null, textWatch)
binding.dia.tag = "LP_DIA"
TimeListEdit(context, aapsLogger, dateUtil, view, R.id.ic_holder, "IC", rh.gs(R.string.ic_label), currentProfile.ic, null, hardLimits.minIC(), hardLimits.maxIC(), 0.1, DecimalFormat("0.0"), save)
basalView = TimeListEdit(context, aapsLogger, dateUtil, view, R.id.basal_holder, "BASAL", rh.gs(R.string.basal_label) + ": " + sumLabel(), currentProfile.basal, null, pumpDescription.basalMinimumRate, pumpDescription.basalMaximumRate, 0.01, DecimalFormat("0.00"), save)
TimeListEdit(context, aapsLogger, dateUtil, view, R.id.ic_holder, "IC", rh.gs(R.string.ic_long_label), currentProfile.ic, null, doubleArrayOf(hardLimits.minIC(), hardLimits.maxIC()), null, 0.1, DecimalFormat ("0.0"), save)
basalView = TimeListEdit(context, aapsLogger, dateUtil, view, R.id.basal_holder, "BASAL", rh.gs(R.string.basal_long_label) + ": " + sumLabel(), currentProfile.basal, null, doubleArrayOf(pumpDescription.basalMinimumRate, pumpDescription.basalMaximumRate), null, 0.01, DecimalFormat("0.00"), save)
if (units == Constants.MGDL) {
TimeListEdit(context, aapsLogger, dateUtil, view, R.id.isf_holder, "ISF", rh.gs(R.string.isf_label), currentProfile.isf, null, HardLimits.MIN_ISF, HardLimits.MAX_ISF, 1.0, DecimalFormat("0"), save)
TimeListEdit(context, aapsLogger, dateUtil, view, R.id.target, "TARGET", rh.gs(R.string.target_label), currentProfile.targetLow, currentProfile.targetHigh, HardLimits.VERY_HARD_LIMIT_TARGET_BG[0], HardLimits.VERY_HARD_LIMIT_TARGET_BG[1], 1.0, DecimalFormat("0"), save)
val isfRange = doubleArrayOf(HardLimits.MIN_ISF, HardLimits.MAX_ISF)
TimeListEdit(context, aapsLogger, dateUtil, view, R.id.isf_holder, "ISF", rh.gs(R.string.isf_long_label), currentProfile.isf, null, isfRange , null, 1.0, DecimalFormat("0"), save)
TimeListEdit(context, aapsLogger, dateUtil, view, R.id.target_holder, "TARGET", rh.gs(R.string.target_long_label), currentProfile.targetLow, currentProfile.targetHigh, HardLimits.VERY_HARD_LIMIT_MIN_BG, HardLimits.VERY_HARD_LIMIT_TARGET_BG, 1.0, DecimalFormat("0"), save)
} else {
TimeListEdit(context, aapsLogger, dateUtil, view, R.id.isf_holder, "ISF", rh.gs(R.string.isf_label), currentProfile.isf, null, Profile.fromMgdlToUnits(HardLimits.MIN_ISF, GlucoseUnit.MMOL), Profile.fromMgdlToUnits(HardLimits.MAX_ISF, GlucoseUnit.MMOL), 0.1, DecimalFormat("0.0"), save)
TimeListEdit(context, aapsLogger, dateUtil, view, R.id.target, "TARGET", rh.gs(R.string.target_label), currentProfile.targetLow, currentProfile.targetHigh, Profile.fromMgdlToUnits(HardLimits.VERY_HARD_LIMIT_TARGET_BG[0], GlucoseUnit.MMOL), Profile.fromMgdlToUnits(HardLimits.VERY_HARD_LIMIT_TARGET_BG[1], GlucoseUnit.MMOL), 0.1, DecimalFormat("0.0"), save)
val isfRange = doubleArrayOf(roundUp(Profile.fromMgdlToUnits(HardLimits.MIN_ISF, GlucoseUnit.MMOL)),
roundDown(Profile.fromMgdlToUnits(HardLimits.MAX_ISF, GlucoseUnit.MMOL)))
TimeListEdit(context, aapsLogger, dateUtil, view, R.id.isf_holder, "ISF", rh.gs(R.string.isf_long_label), currentProfile.isf, null,isfRange , null, 0.1, DecimalFormat("0.0"), save)
val range1 = doubleArrayOf(roundUp(Profile.fromMgdlToUnits(HardLimits.VERY_HARD_LIMIT_MIN_BG[0], GlucoseUnit.MMOL)),
roundDown(Profile.fromMgdlToUnits(HardLimits.VERY_HARD_LIMIT_MIN_BG[1], GlucoseUnit.MMOL)))
val range2 = doubleArrayOf(roundUp(Profile.fromMgdlToUnits(HardLimits.VERY_HARD_LIMIT_MAX_BG[0], GlucoseUnit.MMOL)),
roundDown(Profile.fromMgdlToUnits(HardLimits.VERY_HARD_LIMIT_MAX_BG[1], GlucoseUnit.MMOL)))
Log.i("TimeListEdit", "build: range1" + range1[0] + " " + range1[1] + " range2" + range2[0] + " " + range2[1])
TimeListEdit(context, aapsLogger, dateUtil, view, R.id.target_holder, "TARGET", rh.gs(R.string.target_long_label), currentProfile.targetLow, currentProfile.targetHigh, range1 , range2, 0.1, DecimalFormat("0.0"), save)
}
// Spinner
@ -175,6 +187,8 @@ class LocalProfileFragment : DaggerFragment() {
binding.basalGraph.show(ProfileSealed.Pure(it))
binding.icGraph.show(ProfileSealed.Pure(it))
binding.isfGraph.show(ProfileSealed.Pure(it))
binding.targetGraph.show(ProfileSealed.Pure(it))
binding.insulinGraph.show(activePlugin.activeInsulin, SafeParse.stringToDouble(binding.dia.text))
}
binding.profileAdd.setOnClickListener {
@ -265,6 +279,14 @@ class LocalProfileFragment : DaggerFragment() {
updateGUI()
}
private fun roundUp(number: Double): Double {
return number.toBigDecimal().setScale(1, RoundingMode.UP).toDouble()
}
private fun roundDown(number: Double): Double {
return number.toBigDecimal().setScale(1, RoundingMode.DOWN).toDouble()
}
private fun updateGUI() {
if (_binding == null) return
val isValid = localProfilePlugin.isValidEditState(activity)

View file

@ -7,8 +7,6 @@ import android.view.View
import android.view.ViewGroup
import androidx.recyclerview.widget.LinearLayoutManager
import androidx.recyclerview.widget.RecyclerView
import androidx.work.ListenableWorker
import androidx.work.workDataOf
import dagger.android.support.DaggerFragment
import info.nightscout.androidaps.R
import info.nightscout.androidaps.database.AppRepository
@ -118,7 +116,10 @@ class BGSourceFragment : DaggerFragment() {
val glucoseValue = glucoseValues[position]
holder.binding.ns.visibility = (glucoseValue.interfaceIDs.nightscoutId != null).toVisibility()
holder.binding.invalid.visibility = (!glucoseValue.isValid).toVisibility()
holder.binding.date.text = dateUtil.dateAndTimeString(glucoseValue.timestamp)
val sameDayPrevious = position > 0 && dateUtil.isSameDay(glucoseValue.timestamp, glucoseValues[position-1].timestamp)
holder.binding.date.visibility = sameDayPrevious.not().toVisibility()
holder.binding.date.text = dateUtil.dateString(glucoseValue.timestamp)
holder.binding.time.text = dateUtil.timeString(glucoseValue.timestamp)
holder.binding.value.text = glucoseValue.valueToUnitsString(profileFunction.getUnits())
holder.binding.direction.setImageResource(glucoseValue.trendArrow.directionToIcon())
holder.binding.remove.tag = glucoseValue

View file

@ -75,7 +75,7 @@ class MM640gPlugin @Inject constructor(
when (val type = jsonObject.getString("type")) {
"sgv" ->
glucoseValues += CgmSourceTransaction.TransactionGlucoseValue(
timestamp = jsonObject.getLong("sgv"),
timestamp = jsonObject.getLong("date"),
value = jsonObject.getDouble("sgv"),
raw = jsonObject.getDouble("sgv"),
noise = null,

View file

@ -55,12 +55,8 @@ open class DataReceiver : DaggerBroadcastReceiver() {
Intents.NS_EMULATOR ->
OneTimeWorkRequest.Builder(MM640gPlugin.MM640gWorker::class.java)
.setInputData(Data.Builder().also {
it.copyDouble(Intents.EXTRA_BG_ESTIMATE, bundle)
it.copyString(Intents.EXTRA_BG_SLOPE_NAME, bundle)
it.copyLong(Intents.EXTRA_TIMESTAMP, bundle)
it.copyDouble(Intents.EXTRA_RAW, bundle)
it.copyInt(Intents.EXTRA_SENSOR_BATTERY, bundle, -1)
it.copyString(Intents.XDRIP_DATA_SOURCE_DESCRIPTION, bundle)
it.copyString("collection", bundle)
it.copyString("data", bundle)
}.build()).build()
Telephony.Sms.Intents.SMS_RECEIVED_ACTION ->
OneTimeWorkRequest.Builder(SmsCommunicatorPlugin.SmsCommunicatorWorker::class.java)

View file

@ -57,6 +57,8 @@ public class TimeListEdit {
private final double step;
private final double min;
private final double max;
private final double min2;
private final double max2;
private final NumberFormat formatter;
private final Runnable save;
private LinearLayout layout;
@ -68,7 +70,7 @@ public class TimeListEdit {
Context context,
AAPSLogger aapsLogger,
DateUtil dateUtil,
View view, int resLayoutId, String tagPrefix, String label, JSONArray data1, JSONArray data2, double min, double max, double step, NumberFormat formatter, Runnable save) {
View view, int resLayoutId, String tagPrefix, String label, JSONArray data1, JSONArray data2, double[] range1, double[] range2, double step, NumberFormat formatter, Runnable save) {
this.context = context;
this.aapsLogger = aapsLogger;
this.dateUtil = dateUtil;
@ -79,8 +81,10 @@ public class TimeListEdit {
this.data1 = data1;
this.data2 = data2;
this.step = step;
this.min = min;
this.max = max;
this.min = range1[0];
this.max = range1[1];
this.min2 = range2 != null ? range2[0] : 0;
this.max2 = range2 != null ? range2[1] : 0;
this.formatter = formatter;
this.save = save;
buildView();
@ -177,7 +181,13 @@ public class TimeListEdit {
numberPickers1[position].setTextWatcher(new TextWatcher() {
@Override
public void afterTextChanged(Editable s) {
editItem(position, secondFromMidnight(position), SafeParse.stringToDouble(numberPickers1[position].getText()), value2(position));
Double value1 = SafeParse.stringToDouble(numberPickers1[position].getText());
Double value2 = value2(position);
if (data2 != null && value1 > value2) {
value2 = value1;
numberPickers2[position].setValue(value2);
}
editItem(position, secondFromMidnight(position), value1, value2);
callSave();
log();
}
@ -197,7 +207,13 @@ public class TimeListEdit {
numberPickers2[position].setTextWatcher(new TextWatcher() {
@Override
public void afterTextChanged(Editable s) {
editItem(position, secondFromMidnight(position), value1(position), SafeParse.stringToDouble(numberPickers2[position].getText()));
Double value1 = value1(position);
Double value2 = SafeParse.stringToDouble(numberPickers2[position].getText());
if (data2 != null && value2 < value1) {
value1 = value2;
numberPickers1[position].setValue(value1);
}
editItem(position, secondFromMidnight(position), value1, value2);
callSave();
log();
}
@ -246,7 +262,7 @@ public class TimeListEdit {
fillSpinner(timeSpinner, secondFromMidnight(i), previous, next);
editText1.setParams(value1(i), min, max, step, formatter, false, null);
editText2.setParams(value2(i), min, max, step, formatter, false, null);
editText2.setParams(value2(i), min2, max2, step, formatter, false, null);
if (data2 == null) {
editText2.setVisibility(View.GONE);

View file

@ -347,6 +347,8 @@ class BolusWizard @Inject constructor(
)
else
commonProcessing(ctx)
} else {
OKDialog.show(ctx, rh.gs(R.string.boluswizard), rh.gs(R.string.no_action_selected))
}
}

View file

@ -0,0 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
<item
android:width="26dp"
android:height="26dp"
android:drawable="@drawable/ic_xdrip" />
</layer-list>

View file

@ -0,0 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
<item
android:width="26dp"
android:height="26dp"
android:drawable="@drawable/ic_cp_bolus_carbs" />
</layer-list>

View file

@ -0,0 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
<item
android:width="26dp"
android:height="26dp"
android:drawable="@drawable/ic_bolus" />
</layer-list>

View file

@ -0,0 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
<item
android:width="26dp"
android:height="26dp"
android:drawable="@drawable/ic_fortyfiveup" />
</layer-list>

View file

@ -0,0 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android" >
<item android:drawable="@drawable/cb_backgroud_bg" />
</selector>

View file

@ -0,0 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android" >
<item android:drawable="@drawable/cb_backgroud_cob" />
</selector>

View file

@ -0,0 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android" >
<item android:drawable="@drawable/cb_backgroud_iob" />
</selector>

View file

@ -0,0 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android" >
<item android:drawable="@drawable/cb_backgroud_trend" />
</selector>

View file

@ -0,0 +1,13 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="48dp"
android:height="48dp"
android:viewportWidth="80"
android:viewportHeight="80">
<path
android:fillAlpha="0.5"
android:fillColor="#FFFFFF"
android:pathData="M 18 54 a 3 3 0 0 0 3 3 L 45 57 A 19 19 0 0 0 62 40 A 19 19 0 0 0 45 24 L 21 24 a 3 3 0 0 0 -3 3 Z M 67 40 A 22 22 0 0 1 45 62 L 19 62 a 6 6 0 0 1 -6 -6 L 13 25 a 6 6 0 0 1 6 -6 L 45 19 A 22 22 0 0 1 67 40"
android:strokeAlpha="0.5" />
</vector>

View file

@ -23,7 +23,7 @@
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:contentDescription="@string/carbs"
android:importantForAccessibility="no"
app:srcCompat="@mipmap/ic_launcher" />
<TextView

View file

@ -23,7 +23,7 @@
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:contentDescription="@string/carbs"
android:importantForAccessibility="no"
app:srcCompat="@mipmap/ic_launcher" />
<TextView

View file

@ -1,68 +1,84 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.cardview.widget.CardView xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:card_view="http://schemas.android.com/apk/res-auto"
android:id="@+id/bg_card"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center"
card_view:cardBackgroundColor="@color/cardColorBackground"
card_view:cardCornerRadius="6dp"
card_view:cardUseCompatPadding="true"
card_view:contentPadding="6dp">
card_view:cardUseCompatPadding="true">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:orientation="horizontal">
android:orientation="vertical">
<TextView
android:id="@+id/date"
android:layout_width="wrap_content"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="16:55"
android:textStyle="bold" />
android:background="@color/list_delimiter"
android:gravity="center"
android:text="1.1.2000"
android:textAppearance="?android:attr/textAppearanceMedium" />
<TextView
android:id="@+id/value"
android:layout_width="wrap_content"
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingStart="10dp"
android:text="Name"
android:textStyle="bold" />
android:gravity="center"
android:orientation="horizontal"
android:padding="6dp">
<ImageView
android:id="@+id/direction"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:layout_gravity="center_vertical"
card_view:srcCompat="@drawable/ic_flat" />
<TextView
android:id="@+id/time"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="16:55"
android:textStyle="bold" />
<TextView
android:id="@+id/ns"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:paddingStart="10dp"
android:text="NS"
android:textAlignment="viewEnd"
android:textColor="@color/colorSetTempButton" />
<TextView
android:id="@+id/value"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:paddingStart="10dp"
android:text="Name"
android:textStyle="bold" />
<TextView
android:id="@+id/invalid"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:paddingStart="10dp"
android:text="@string/invalid"
android:textColor="@android:color/holo_red_light" />
<ImageView
android:id="@+id/direction"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:layout_gravity="center_vertical"
card_view:srcCompat="@drawable/ic_flat" />
<TextView
android:id="@+id/remove"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:paddingStart="10dp"
android:paddingEnd="5dp"
android:text="@string/remove_button"
android:textAlignment="viewEnd"
android:textColor="@android:color/holo_orange_light" />
<TextView
android:id="@+id/ns"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:paddingStart="10dp"
android:text="NS"
android:textAlignment="viewEnd"
android:textColor="@color/colorSetTempButton" />
<TextView
android:id="@+id/invalid"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:paddingStart="10dp"
android:text="@string/invalid"
android:textColor="@android:color/holo_red_light" />
<TextView
android:id="@+id/remove"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:paddingStart="10dp"
android:paddingEnd="5dp"
android:text="@string/remove_button"
android:textAlignment="viewEnd"
android:textColor="@android:color/holo_orange_light" />
</LinearLayout>
</LinearLayout>

View file

@ -8,7 +8,8 @@
<TableRow
android:layout_width="fill_parent"
android:layout_height="wrap_content">
android:layout_height="wrap_content"
android:focusable="true">
<TextView
android:layout_width="wrap_content"
@ -20,7 +21,6 @@
android:textSize="14sp"
app:drawableStartCompat="@drawable/ic_cp_age_sensor" />
<TextView
android:id="@+id/sensor_age_label"
android:layout_width="wrap_content"
@ -83,7 +83,8 @@
<TableRow
android:layout_width="fill_parent"
android:layout_height="wrap_content">
android:layout_height="wrap_content"
android:focusable="true">
<TextView
android:layout_width="wrap_content"
@ -158,9 +159,11 @@
<TableRow
android:layout_width="fill_parent"
android:layout_height="wrap_content">
android:layout_height="wrap_content"
android:focusable="true">
<TextView
android:id="@+id/cannula_or_patch"
android:layout_width="wrap_content"
android:layout_height="25dp"
android:gravity="center_vertical"
@ -229,7 +232,8 @@
<TableRow
android:layout_width="fill_parent"
android:layout_height="wrap_content">
android:layout_height="wrap_content"
android:focusable="true">
<TextView
android:id="@+id/pb_label"

View file

@ -8,7 +8,8 @@
<TableRow
android:layout_width="fill_parent"
android:layout_height="wrap_content">
android:layout_height="wrap_content"
android:focusable="true">
<TextView
android:layout_width="wrap_content"
@ -63,7 +64,8 @@
<TableRow
android:layout_width="fill_parent"
android:layout_height="wrap_content">
android:layout_height="wrap_content"
android:focusable="true">
<TextView
android:layout_width="wrap_content"
@ -118,7 +120,8 @@
<TableRow
android:layout_width="fill_parent"
android:layout_height="wrap_content">
android:layout_height="wrap_content"
android:focusable="true">
<TextView
android:layout_width="wrap_content"
@ -171,7 +174,8 @@
<TableRow
android:layout_width="fill_parent"
android:layout_height="wrap_content">
android:layout_height="wrap_content"
android:focusable="true">
<TextView
android:id="@+id/pb_label"

View file

@ -26,7 +26,7 @@
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:contentDescription="@string/overview_calibration"
android:importantForAccessibility="no"
app:srcCompat="@drawable/ic_calibration" />
<TextView

View file

@ -25,7 +25,7 @@
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:contentDescription="@string/carbs"
android:importantForAccessibility="no"
app:srcCompat="@drawable/ic_cp_bolus_carbs" />
<TextView

View file

@ -26,7 +26,7 @@
android:id="@+id/icon"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:contentDescription="@string/careportal_profileswitch"
android:importantForAccessibility="no"
app:srcCompat="@drawable/ic_actions_profileswitch" />
<TextView

View file

@ -25,7 +25,7 @@
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:contentDescription="@string/virtualpump_extendedbolus_label"
android:importantForAccessibility="no"
app:srcCompat="@drawable/ic_actions_startextbolus" />
<TextView

View file

@ -25,7 +25,7 @@
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:contentDescription="@string/primefill"
android:importantForAccessibility="no"
app:srcCompat="@drawable/ic_cp_pump_canula" />
<TextView

View file

@ -25,7 +25,7 @@
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:contentDescription="@string/overview_insulin_label"
android:importantForAccessibility="no"
app:srcCompat="@drawable/ic_bolus" />
<TextView

View file

@ -26,7 +26,7 @@
android:id="@+id/loop_icon"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:contentDescription="@string/boluswizard"
android:importantForAccessibility="no"
app:srcCompat="@drawable/ic_loop_closed" />
<TextView

View file

@ -25,7 +25,7 @@
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:contentDescription="@string/careportal_profileswitch"
android:importantForAccessibility="no"
app:srcCompat="@drawable/ic_actions_profileswitch" />
<TextView

View file

@ -25,7 +25,7 @@
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:contentDescription="@string/tempbasal_label"
android:importantForAccessibility="no"
app:srcCompat="@drawable/ic_cp_basal_start" />
<TextView

View file

@ -25,7 +25,7 @@
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:contentDescription="@string/careportal_temporarytarget"
android:importantForAccessibility="no"
app:srcCompat="@drawable/ic_temptarget_high" />
<TextView

View file

@ -25,30 +25,21 @@
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:contentDescription="@string/overview_treatment_label"
android:importantForAccessibility="no"
app:srcCompat="@drawable/ic_bolus" />
</RelativeLayout>
<LinearLayout
android:id="@+id/spacer"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:padding="5dp" >
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_centerHorizontal="true"
android:layout_centerVertical="true"
android:layout_centerInParent="true"
android:layout_gravity="center"
android:layout_marginLeft="10dp"
android:layout_marginRight="10dp"
android:text="@string/overview_treatment_label"
android:textAlignment="center"
android:textAppearance="?android:attr/textAppearanceLarge" />
</LinearLayout>
</RelativeLayout>
<LinearLayout
android:id="@+id/recordOnlyLayout"

View file

@ -25,7 +25,7 @@
<ImageView
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:contentDescription="@string/boluswizard"
android:importantForAccessibility="no"
app:srcCompat="@drawable/ic_calculator" />
<TextView
@ -59,6 +59,7 @@
android:layout_height="match_parent">
<TextView
android:id="@+id/bg_input_label"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1"
@ -70,7 +71,8 @@
<info.nightscout.androidaps.utils.ui.NumberPicker
android:id="@+id/bg_input"
android:layout_width="130dp"
android:layout_height="40dp" />
android:layout_height="40dp"
app:customContentDescription="@string/a11y_current_bg" />
<TextView
android:id="@+id/bg_units"
@ -89,9 +91,11 @@
android:layout_height="match_parent">
<TextView
android:id="@+id/carbs_input_label"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1"
android:labelFor="@id/carbs_input"
android:padding="10dp"
android:text="@string/treatments_wizard_carbs_label"
android:textAppearance="@style/TextAppearance.AppCompat.Small"
@ -101,8 +105,8 @@
android:id="@+id/carbs_input"
android:layout_width="130dp"
android:layout_height="40dp"
android:layout_gravity="center_horizontal" />
android:layout_gravity="center_horizontal"
app:customContentDescription="@string/treatments_wizard_carbs_label" />
<TextView
android:layout_width="wrap_content"
@ -127,6 +131,7 @@
android:orientation="horizontal">
<TextView
android:id="@+id/correction_input_label"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
@ -135,32 +140,26 @@
android:textAppearance="@style/TextAppearance.AppCompat.Small"
android:textStyle="bold" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:text=" %"
android:textAppearance="@style/TextAppearance.AppCompat.Medium"
android:textStyle="bold"
tools:ignore="HardcodedText" />
<CheckBox
android:id="@+id/correction_percent"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:checked="false"
android:padding="2dp" />
android:layoutDirection="rtl"
android:padding="2dp"
android:text="%"
android:textAppearance="@style/TextAppearance.AppCompat.Medium"
android:textStyle="bold" />
</LinearLayout>
<info.nightscout.androidaps.utils.ui.NumberPicker
android:id="@+id/correction_input"
android:layout_width="130dp"
android:layout_height="40dp"
android:layout_gravity="center_horizontal" />
android:layout_gravity="center_horizontal"
app:customContentDescription="@string/a11_correction_units" />
<TextView
android:id="@+id/correction_unit"
@ -255,77 +254,48 @@
<CheckBox
android:id="@+id/calculation_checkbox"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:checked="false" />
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_height="fill_parent"
android:layout_gravity="center_vertical"
android:checked="false"
android:contentDescription="@string/show_calculation"
app:srcCompat="@drawable/ic_visibility" />
android:drawableEnd="@drawable/ic_visibility" />
<ImageView
android:id="@+id/bg_enabled_icon"
<CheckBox
android:id="@+id/bg_checkbox_icon"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:paddingStart="-11dp"
android:paddingEnd="-11dp"
android:scaleX="0.5"
android:scaleY="0.5"
app:srcCompat="@drawable/ic_xdrip"/>
android:layout_height="fill_parent"
android:button="@drawable/checkbox_bg_icon"
android:checked="true"
android:contentDescription="@string/treatments_wizard_bg_label" />
<ImageView
android:id="@+id/trend_enabled_icon"
<CheckBox
android:id="@+id/trend_checkbox_icon"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:paddingStart="-11dp"
android:paddingEnd="-11dp"
android:scaleX="0.5"
android:scaleY="0.5"
app:srcCompat="@drawable/ic_fortyfiveup" />
android:layout_height="fill_parent"
android:button="@drawable/checkbox_trend_icon"
android:checked="true"
android:contentDescription="@string/bg_trend_label" />
<ImageView
android:id="@+id/iob_enabled_icon"
<CheckBox
android:id="@+id/iob_checkbox_icon"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:paddingStart="-11dp"
android:paddingEnd="-11dp"
android:scaleX="0.5"
android:scaleY="0.5"
app:srcCompat="@drawable/ic_bolus" />
android:layout_height="fill_parent"
android:button="@drawable/checkbox_iob_icon"
android:checked="true"
android:contentDescription="@string/iob" />
<ImageView
android:id="@+id/cob_enabled_icon"
<CheckBox
android:id="@+id/cob_checkbox_icon"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:paddingStart="-11dp"
android:paddingEnd="-11dp"
android:scaleX="0.5"
android:scaleY="0.5"
app:srcCompat="@drawable/ic_cp_bolus_carbs" />
android:layout_height="fill_parent"
android:button="@drawable/checkbox_cob_icon"
android:checked="true"
android:contentDescription="@string/treatments_wizard_cob_label" />
<Button
android:id="@+id/cancel"
style="@style/mdtp_ActionButton.Text"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="@string/mdtp_cancel"
android:textAlignment="textEnd" />
<include
android:id="@+id/okcancel"
layout="@layout/okcancel" />
<Button
android:id="@+id/ok"
style="@style/mdtp_ActionButton.Text"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginEnd="8dp"
android:text="@string/mdtp_ok" />
</LinearLayout>
<View
@ -350,6 +320,7 @@
android:orientation="horizontal">
<TextView
android:id="@+id/carb_time_input_label"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
@ -360,27 +331,23 @@
android:textAppearance="@style/TextAppearance.AppCompat.Small"
android:textStyle="bold" />
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:contentDescription="@string/alarm"
android:src="@drawable/ic_access_alarm_24dp" />
<CheckBox
android:id="@+id/alarm"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:checked="false"
android:contentDescription="set carb timer alarm"
android:drawableEnd="@drawable/ic_access_alarm_24dp"
android:layoutDirection="rtl"
android:padding="2dp" />
<info.nightscout.androidaps.utils.ui.NumberPicker
android:id="@+id/carb_time_input"
android:layout_width="130dp"
android:layout_height="40dp"
android:layout_gravity="center" />
android:layout_gravity="center"
app:contentDescription="carb time" />
<TextView
android:layout_width="wrap_content"
@ -402,6 +369,7 @@
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:labelFor="@id/profile"
android:padding="10dp"
android:text="@string/profile_label"
android:textAppearance="@style/TextAppearance.AppCompat.Small"
@ -414,7 +382,6 @@
android:layout_gravity="center_vertical|center_horizontal"
android:layout_weight="0.5" />
<CheckBox
android:id="@+id/sb_checkbox"
android:layout_width="wrap_content"
@ -445,38 +412,24 @@
android:layout_width="match_parent"
android:layout_height="match_parent">
<CheckBox
android:id="@+id/bg_checkbox"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:width="32dp"
android:checked="true" />
<LinearLayout
android:layout_width="match_parent"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:orientation="horizontal">
<TextView
<CheckBox
android:id="@+id/bg_checkbox"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:width="24dp"
android:text="@string/treatments_wizard_bg_label"
android:textAppearance="?android:attr/textAppearanceSmall" />
android:checked="true"
android:text="@string/treatments_wizard_bg_label" />
<CheckBox
android:id="@+id/tt_checkbox"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:width="32dp"
android:checked="false" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:width="30dp"
android:text="@string/treatments_wizard_tt_label"
android:textAppearance="?android:attr/textAppearanceSmall" />
android:checked="false"
android:text="@string/treatments_wizard_tt_label" />
</LinearLayout>
@ -506,15 +459,9 @@
android:id="@+id/bg_trend_checkbox"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:width="32dp"
android:checked="false" />
android:checked="false"
android:text="@string/bg_trend_label" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:width="86dp"
android:text="@string/bg_trend_label"
android:textAppearance="?android:attr/textAppearanceSmall" />
<TextView
android:id="@+id/bg_trend"
@ -542,15 +489,8 @@
android:id="@+id/iob_checkbox"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:width="32dp"
android:checked="true" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:width="130dp"
android:text="@string/iob"
android:textAppearance="?android:attr/textAppearanceSmall" />
android:checked="true"
android:text="@string/iob" />
<TextView
android:layout_width="wrap_content"
@ -578,14 +518,8 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:width="32dp"
android:checked="false" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:width="86dp"
android:text="@string/treatments_wizard_cob_label"
android:textAppearance="?android:attr/textAppearanceSmall" />
android:checked="false"
android:text="@string/treatments_wizard_cob_label" />
<TextView
android:id="@+id/cob"
@ -607,19 +541,27 @@
<TableRow
android:layout_width="match_parent"
android:layout_height="match_parent">
android:layout_height="match_parent"
android:focusable="true">
<TextView
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:width="32dp" />
android:layout_height="match_parent"
android:orientation="horizontal">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:width="86dp"
android:text="@string/treatments_wizard_carbs_label"
android:textAppearance="?android:attr/textAppearanceSmall" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:width="32dp" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:width="86dp"
android:text="@string/treatments_wizard_carbs_label"
android:textAppearance="?android:attr/textAppearanceSmall" />
</LinearLayout>
<TextView
android:id="@+id/carbs"
@ -642,19 +584,27 @@
<TableRow
android:layout_width="match_parent"
android:layout_height="match_parent">
android:layout_height="match_parent"
android:focusable="true">
<TextView
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:width="32dp" />
android:layout_height="match_parent"
android:orientation="horizontal">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:width="86dp"
android:text="@string/superbolus"
android:textAppearance="?android:attr/textAppearanceSmall" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:width="32dp" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:width="86dp"
android:text="@string/superbolus"
android:textAppearance="?android:attr/textAppearanceSmall" />
</LinearLayout>
<TextView
android:id="@+id/sb"
@ -676,19 +626,27 @@
<TableRow
android:layout_width="match_parent"
android:layout_height="match_parent">
android:layout_height="match_parent"
android:focusable="true">
<TextView
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:width="32dp" />
android:layout_height="match_parent"
android:orientation="horizontal">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:width="86dp"
android:text="@string/treatments_wizard_correction_label"
android:textAppearance="?android:attr/textAppearanceSmall" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:width="32dp" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:width="86dp"
android:text="@string/treatments_wizard_correction_label"
android:textAppearance="?android:attr/textAppearanceSmall" />
</LinearLayout>
<TextView
android:layout_width="wrap_content"
@ -704,6 +662,7 @@
android:width="50dp"
android:gravity="end"
android:textAppearance="?android:attr/textAppearanceSmall" />
</TableRow>
</TableLayout>
@ -712,4 +671,4 @@
</LinearLayout>
</ScrollView>
</ScrollView>

View file

@ -25,7 +25,7 @@
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:contentDescription="@string/carbs"
android:importantForAccessibility="no"
app:srcCompat="@drawable/ic_calculator" />
<TextView

View file

@ -35,6 +35,40 @@
</LinearLayout>
<View
android:layout_width="fill_parent"
android:layout_height="2dip"
android:layout_marginTop="5dp"
android:layout_marginBottom="5dp"
android:background="@color/list_delimiter" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="10dp"
android:orientation="horizontal">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="10dp"
android:layout_marginBottom="10dp"
android:labelFor="@+id/name"
android:text="@string/profile_name"
android:textAppearance="?android:attr/textAppearanceMedium" />
<EditText
android:id="@+id/name"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginStart="10dp"
android:layout_weight="1"
android:ems="10"
android:importantForAutofill="no"
android:inputType="text" />
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
@ -152,32 +186,13 @@
android:layout_height="wrap_content"
android:orientation="vertical">
<LinearLayout
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="10dp"
android:orientation="horizontal">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="10dp"
android:layout_marginBottom="10dp"
android:labelFor="@+id/name"
android:text="@string/profile_name"
android:textAppearance="?android:attr/textAppearanceMedium" />
<EditText
android:id="@+id/name"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginStart="10dp"
android:layout_weight="1"
android:ems="10"
android:importantForAutofill="no"
android:inputType="text" />
</LinearLayout>
android:gravity="center_horizontal"
android:text="@string/dia_label"
android:textColor="@android:color/white"
android:textSize="20sp" />
<LinearLayout
android:layout_width="match_parent"
@ -210,6 +225,12 @@
</LinearLayout>
<info.nightscout.androidaps.plugins.insulin.ActivityGraph
android:id="@+id/insulin_graph"
android:layout_width="match_parent"
android:layout_height="100dip"
android:layout_margin="20dp" />
</LinearLayout>
<LinearLayout
@ -225,7 +246,7 @@
android:layout_marginBottom="10dp"
android:orientation="vertical" />
<info.nightscout.androidaps.utils.ui.BasalProfileGraph
<info.nightscout.androidaps.utils.ui.IcProfileGraph
android:id="@+id/ic_graph"
android:layout_width="match_parent"
android:layout_height="100dip"
@ -277,11 +298,23 @@
<LinearLayout
android:id="@+id/target"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginBottom="10dp"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical">
<LinearLayout
android:id="@+id/target_holder"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginBottom="10dp"
android:orientation="vertical" />
<info.nightscout.androidaps.utils.ui.TargetBgProfileGraph
android:id="@+id/target_graph"
android:layout_width="match_parent"
android:layout_height="100dip"
android:layout_margin="20dp" />
</LinearLayout>
<Button

View file

@ -20,6 +20,7 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:focusable="true"
android:orientation="horizontal">
<TextView
@ -65,7 +66,9 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:focusable="true"
android:orientation="horizontal"
android:screenReaderFocusable="true">
<TextView
android:layout_width="match_parent"
@ -110,6 +113,7 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:focusable="true"
android:orientation="horizontal">
<TextView
@ -155,6 +159,7 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:focusable="true"
android:orientation="horizontal">
<TextView
@ -200,6 +205,7 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:focusable="true"
android:orientation="horizontal">
<TextView
@ -245,6 +251,7 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:focusable="true"
android:orientation="horizontal">
<TextView
@ -290,6 +297,7 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:focusable="true"
android:orientation="horizontal">
<TextView
@ -335,6 +343,7 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:focusable="true"
android:orientation="horizontal">
<TextView
@ -380,6 +389,7 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:focusable="true"
android:orientation="horizontal">
<TextView
@ -425,6 +435,7 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:focusable="true"
android:orientation="horizontal">
<TextView
@ -470,6 +481,7 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:focusable="true"
android:orientation="horizontal">
<TextView

View file

@ -27,7 +27,8 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"
@ -86,10 +87,20 @@
</LinearLayout>
<View
android:layout_width="fill_parent"
android:layout_height="2dip"
android:layout_marginLeft="20dp"
android:layout_marginTop="5dp"
android:layout_marginRight="20dp"
android:layout_marginBottom="5dp"
android:background="@color/list_delimiter" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"
@ -134,7 +145,8 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"
@ -179,7 +191,8 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"
@ -224,7 +237,8 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"
@ -269,7 +283,8 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"
@ -314,7 +329,8 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"
@ -359,7 +375,8 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"
@ -418,6 +435,15 @@
</LinearLayout>
<View
android:layout_width="fill_parent"
android:layout_height="2dip"
android:layout_marginLeft="20dp"
android:layout_marginTop="5dp"
android:layout_marginRight="20dp"
android:layout_marginBottom="5dp"
android:background="@color/list_delimiter" />
<View
android:layout_width="fill_parent"
android:layout_height="0dip"
@ -430,7 +456,8 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"
@ -475,7 +502,8 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"
@ -520,7 +548,8 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"

View file

@ -21,7 +21,7 @@
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:contentDescription="@string/quickwizard"
android:importantForAccessibility="no"
app:srcCompat="@drawable/ic_quick_wizard" />
<TextView

View file

@ -12,15 +12,16 @@
android:paddingBottom="4dp">
<ImageView
android:id="@+id/cannula_or_patch"
android:layout_width="40dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:scaleX = "2"
android:scaleY = "2"
android:gravity="center_vertical"
android:scaleType="centerInside"
android:scaleX="2"
android:scaleY="2"
app:srcCompat="@drawable/ic_cp_age_cannula"
android:contentDescription="@string/cannula" />
android:contentDescription="@string/statuslights_cannula_age" />
<TextView
android:id="@+id/cannula_age"
@ -37,8 +38,8 @@
android:layout_weight="1"
android:gravity="center_vertical"
android:scaleType="centerInside"
android:scaleX="1.8"
android:scaleY="1.8"
android:scaleX="1.6"
android:scaleY="1.6"
app:srcCompat="@drawable/ic_cp_age_insulin"
android:contentDescription="@string/insulin_label" />

View file

@ -12,6 +12,20 @@
android:layout_height="wrap_content"
android:orientation="vertical">
<TextView
android:id="@+id/date"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="5dp"
android:layout_marginTop="5dp"
android:layout_marginRight="5dp"
android:layout_marginBottom="5dp"
android:background="@color/list_delimiter"
android:gravity="center"
android:text="1.1.2000"
android:textAppearance="?android:attr/textAppearanceMedium"
tools:ignore="HardcodedText" />
<LinearLayout
android:id="@+id/metadata_layout"
android:layout_width="match_parent"
@ -29,11 +43,11 @@
tools:ignore="HardcodedText,RtlSymmetry" />
<TextView
android:id="@+id/date"
android:id="@+id/calc_time"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="5dp"
android:text="1.1.2000"
android:text="11:45"
tools:ignore="HardcodedText,RtlSymmetry" />
<TextView
@ -65,17 +79,17 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:layout_marginStart="15dp"
android:layout_marginStart="5dp"
android:gravity="center"
android:text="{fa-clock-o}"
tools:ignore="HardcodedText,RtlSymmetry" />
<TextView
android:id="@+id/bolus_date"
android:id="@+id/bolus_time"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="5dp"
android:text="1.1.2000"
android:text="11:45"
tools:ignore="HardcodedText,RtlSymmetry" />
<TextView
@ -173,17 +187,17 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:layout_marginStart="15dp"
android:layout_marginStart="5dp"
android:gravity="center"
android:text="{fa-clock-o}"
tools:ignore="HardcodedText,RtlSymmetry" />
<TextView
android:id="@+id/carbs_date"
android:id="@+id/carbs_time"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="5dp"
android:text="1.1.2000"
android:text="11:45"
tools:ignore="HardcodedText,RtlSymmetry" />
<TextView
@ -258,6 +272,7 @@
</LinearLayout>
<View
android:id="@+id/delimiter"
android:layout_width="fill_parent"
android:layout_height="2dip"
android:layout_marginLeft="5dp"

View file

@ -12,13 +12,26 @@
android:layout_height="wrap_content"
android:orientation="vertical">
<TextView
android:id="@+id/date"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="5dp"
android:layout_marginTop="5dp"
android:layout_marginRight="5dp"
android:layout_marginBottom="5dp"
android:background="@color/list_delimiter"
android:gravity="center"
android:text="1.1.2000"
android:textAppearance="?android:attr/textAppearanceMedium"
tools:ignore="HardcodedText" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:baselineAligned="true"
android:orientation="horizontal">
<com.joanzapata.iconify.widget.IconTextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
@ -30,11 +43,11 @@
tools:ignore="HardcodedText" />
<TextView
android:id="@+id/date"
android:id="@+id/time"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:paddingEnd="10dp"
android:text="1.1.2000 18:00"
android:text="18:00"
android:textAppearance="?android:attr/textAppearanceSmall"
tools:ignore="HardcodedText,RtlSymmetry" />
@ -111,6 +124,7 @@
</LinearLayout>
<View
android:id="@+id/delimiter"
android:layout_width="fill_parent"
android:layout_height="2dip"
android:layout_marginStart="5dp"

View file

@ -12,13 +12,26 @@
android:layout_height="wrap_content"
android:orientation="vertical">
<TextView
android:id="@+id/date"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="5dp"
android:layout_marginTop="5dp"
android:layout_marginRight="5dp"
android:layout_marginBottom="5dp"
android:background="@color/list_delimiter"
android:gravity="center"
android:text="1.1.2000"
android:textAppearance="?android:attr/textAppearanceMedium"
tools:ignore="HardcodedText" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:baselineAligned="true"
android:orientation="horizontal">
<com.joanzapata.iconify.widget.IconTextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
@ -30,10 +43,10 @@
tools:ignore="HardcodedText" />
<TextView
android:id="@+id/date"
android:id="@+id/time"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="1.1.2000 18:00"
android:text="18:00"
android:textAppearance="?android:attr/textAppearanceSmall"
tools:ignore="HardcodedText" />
@ -158,6 +171,7 @@
</LinearLayout>
<View
android:id="@+id/delimiter"
android:layout_width="fill_parent"
android:layout_height="2dip"
android:layout_marginBottom="5dp"

View file

@ -12,13 +12,26 @@
android:layout_height="wrap_content"
android:orientation="vertical">
<TextView
android:id="@+id/date"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="5dp"
android:layout_marginTop="5dp"
android:layout_marginRight="5dp"
android:layout_marginBottom="5dp"
android:background="@color/list_delimiter"
android:gravity="center"
android:text="1.1.2000"
android:textAppearance="?android:attr/textAppearanceMedium"
tools:ignore="HardcodedText" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:baselineAligned="true"
android:orientation="horizontal">
<com.joanzapata.iconify.widget.IconTextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
@ -30,11 +43,11 @@
tools:ignore="HardcodedText" />
<TextView
android:id="@+id/date"
android:id="@+id/time"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:paddingStart="10dp"
android:text="1.1.2000 18:00"
android:text="18:00"
android:textAppearance="?android:attr/textAppearanceSmall"
tools:ignore="HardcodedText,RtlSymmetry" />
@ -124,6 +137,7 @@
</LinearLayout>
<View
android:id="@+id/delimiter"
android:layout_width="fill_parent"
android:layout_height="2dip"
android:layout_marginLeft="5dp"

View file

@ -12,13 +12,26 @@
android:layout_height="wrap_content"
android:orientation="vertical">
<TextView
android:id="@+id/date"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="5dp"
android:layout_marginTop="5dp"
android:layout_marginRight="5dp"
android:layout_marginBottom="5dp"
android:background="@color/list_delimiter"
android:gravity="center"
android:text="1.1.2000"
android:textAppearance="?android:attr/textAppearanceMedium"
tools:ignore="HardcodedText" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:baselineAligned="true"
android:orientation="horizontal">
<com.joanzapata.iconify.widget.IconTextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
@ -30,10 +43,10 @@
tools:ignore="HardcodedText" />
<TextView
android:id="@+id/date"
android:id="@+id/time"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="1.1.2000 18:00"
android:text="18:00"
android:textAppearance="?android:attr/textAppearanceSmall"
tools:ignore="HardcodedText" />
@ -178,6 +191,7 @@
</LinearLayout>
<View
android:id="@+id/delimiter"
android:layout_width="fill_parent"
android:layout_height="2dip"
android:layout_marginLeft="5dp"

View file

@ -12,13 +12,26 @@
android:layout_height="wrap_content"
android:orientation="vertical">
<TextView
android:id="@+id/date"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="5dp"
android:layout_marginTop="5dp"
android:layout_marginRight="5dp"
android:layout_marginBottom="5dp"
android:background="@color/list_delimiter"
android:gravity="center"
android:text="1.1.2000"
android:textAppearance="?android:attr/textAppearanceMedium"
tools:ignore="HardcodedText" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:baselineAligned="true"
android:orientation="horizontal">
<com.joanzapata.iconify.widget.IconTextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
@ -30,7 +43,7 @@
tools:ignore="HardcodedText" />
<TextView
android:id="@+id/date"
android:id="@+id/time"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:paddingStart="10dp"
@ -146,6 +159,7 @@
</LinearLayout>
<View
android:id="@+id/delimiter"
android:layout_width="fill_parent"
android:layout_height="2dip"
android:layout_marginLeft="5dp"

View file

@ -5,82 +5,96 @@
android:id="@+id/info_layout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal" >
android:orientation="horizontal">
<TextView
android:id="@+id/date"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="5dp"
android:layout_marginTop="5dp"
android:layout_marginRight="5dp"
android:layout_marginBottom="5dp"
android:background="@color/list_delimiter"
android:gravity="center"
android:text="1.1.2000"
android:textAppearance="?android:attr/textAppearanceMedium"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
tools:ignore="HardcodedText,RtlSymmetry" />
<TextView
android:id="@+id/date"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:paddingStart="10dp"
android:paddingTop="3dp"
android:text="1.1.2021 09:00"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="@+id/iconSource"
app:layout_constraintBottom_toBottomOf="@+id/iconSource"
android:textAppearance="?android:attr/textAppearanceSmall"
tools:ignore="HardcodedText,RtlSymmetry" />
<TextView
android:id="@+id/time"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:paddingStart="10dp"
android:paddingTop="3dp"
android:text="09:00"
android:textAppearance="?android:attr/textAppearanceSmall"
app:layout_constraintBottom_toBottomOf="@+id/iconSource"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="@+id/iconSource"
tools:ignore="HardcodedText,RtlSymmetry" />
<TextView
android:id="@+id/action"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:paddingStart="10dp"
android:paddingTop="3dp"
android:text="USER ENTRY"
app:layout_constraintStart_toEndOf="@id/date"
app:layout_constraintEnd_toStartOf="@+id/iconSource"
app:layout_constraintTop_toTopOf="parent"
android:textAppearance="?android:attr/textAppearanceSmall" />
<TextView
android:id="@+id/action"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:paddingStart="10dp"
android:paddingTop="3dp"
android:text="USER ENTRY"
android:textAppearance="?android:attr/textAppearanceSmall"
app:layout_constraintEnd_toStartOf="@+id/iconSource"
app:layout_constraintStart_toEndOf="@id/time"
app:layout_constraintTop_toBottomOf="@id/date" />
<ImageView
android:id="@+id/iconSource"
android:layout_width="24dp"
android:layout_height="24dp"
android:layout_marginEnd="8dp"
android:orientation="horizontal"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="@+id/action"
app:layout_constraintBottom_toBottomOf="@+id/action"
app:srcCompat="@drawable/ic_cp_bolus_carbs" />
<ImageView
android:id="@+id/iconSource"
android:layout_width="24dp"
android:layout_height="24dp"
android:layout_marginEnd="8dp"
android:orientation="horizontal"
app:layout_constraintBottom_toBottomOf="@+id/action"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="@+id/action"
app:srcCompat="@drawable/ic_cp_bolus_carbs" />
<TextView
android:id="@+id/values"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:paddingStart="20dp"
android:paddingEnd="10dp"
android:text="Values with units"
android:textStyle="bold"
android:visibility="gone"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/action" />
<TextView
android:id="@+id/values"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:paddingStart="20dp"
android:paddingEnd="10dp"
android:textStyle="bold"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/action"
android:visibility="gone"
android:text="Values with units" />
<TextView
android:id="@+id/s"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:paddingStart="20dp"
android:paddingEnd="10dp"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/values"
android:textAppearance="?android:attr/textAppearanceSmall"
android:visibility="gone"
android:text="Notes"
tools:ignore="HardcodedText,RtlSymmetry" />
<View
android:layout_width="fill_parent"
android:layout_height="2dip"
android:layout_marginBottom="5dp"
android:layout_marginStart="5dp"
android:layout_marginEnd="5dp"
android:layout_marginTop="5dp"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/s"
android:background="@color/list_delimiter" />
<TextView
android:id="@+id/notes"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:paddingStart="20dp"
android:paddingEnd="10dp"
android:text="Notes"
android:textAppearance="?android:attr/textAppearanceSmall"
android:visibility="gone"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/values"
tools:ignore="HardcodedText,RtlSymmetry" />
<View
android:id="@+id/delimiter"
android:layout_width="fill_parent"
android:layout_height="2dip"
android:layout_marginStart="5dp"
android:layout_marginTop="5dp"
android:layout_marginEnd="5dp"
android:layout_marginBottom="5dp"
android:background="@color/list_delimiter"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/notes" />
</androidx.constraintlayout.widget.ConstraintLayout>

View file

@ -25,7 +25,8 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="20dp"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"
@ -69,7 +70,8 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"
@ -113,7 +115,8 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"
@ -157,7 +160,8 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"
@ -202,7 +206,8 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"
@ -247,7 +252,8 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"
@ -292,7 +298,8 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"
@ -337,7 +344,8 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"
@ -369,8 +377,6 @@
</LinearLayout>
</LinearLayout>
</ScrollView>

View file

@ -53,7 +53,7 @@
<string name="tempbasals_netinsulin_label_string">Inz:</string>
<string name="tempbasals_iob_label_string">IOB:</string>
<string name="tempbasals_iobtotal_label_string">Celkové IOB:</string>
<string name="treatments_wizard_bg_label">Glykémie</string>
<string name="treatments_wizard_bg_label">Gly</string>
<string name="treatments_wizard_tt_label">DC</string>
<string name="treatments_wizard_carbs_label">Sacharidy</string>
<string name="treatments_wizard_correction_label">Korekce</string>

View file

@ -1,8 +1,55 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="objectives_button_start">Start</string>
<string name="objectives_button_verify">Bekræft</string>
<string name="nth_objective">%1$d. Læringsmål</string>
<string name="objectivenotstarted">Mål %1$d ikke startet</string>
<string name="objectivenotfinished">Mål %1$d ikke startet</string>
<string name="objectives_0_objective">Opsætning af visualisering samt overvågning og analyse af basaler og forhold</string>
<string name="objectives_0_gate">Kontroller, at BG er tilgængelig i Nightscout, og pumpens insulin data bliver uploadet</string>
<string name="objectives_openloop_objective">Starter på et åbent loop</string>
<string name="objectives_openloop_gate">Kør i Open Loop mode i et par dage og aktiver manuelt masser af midlertidige basaler. Opsæt og brug midlertidige mål og standard midlertidige mål (f.eks. for aktivitet eller hypo behandling)</string>
<string name="objectives_maxbasal_objective">Forstå dit åbne loop, herunder dens midlertidige basal anbefalinger</string>
<string name="objectives_maxbasal_gate">Baseret på denne erfaring, beslut hvad max basal skal være og indstil det både på pumpen og i indstillinger</string>
<string name="objectives_maxiobzero_objective">Begynde at bruge lukket loop med lav glukose suspendering</string>
<string name="objectives_maxiobzero_gate">Kør i lukket loop med max IOB = 0 i et par dage uden for mange LGS-begivenheder</string>
<string name="objectives_maxiob_objective">Tuning af lukket loop, hæv max IOB over 0 og sænk gradvist BG målet</string>
<string name="objectives_maxiob_gate">Kør i et par dage, og mindst én nat uden lave BG alarmer, før du sætter målet for BG ned</string>
<string name="objectives_autosens_objective">Justér om nødvendigt basaler og forhold og aktivér derefter auto-sens</string>
<string name="objectives_autosens_gate">1 uges vellykket looping i dagtimerne med alle måltider tastet ind</string>
<string name="objectives_smb_objective">Aktivering af yderligere funktioner til brug i dagtimerne, såsom SMB</string>
<string name="objectives_auto_objective">Aktiverer automatisering</string>
<string name="objectives_smb_gate">Du skal læse wikien og hæve maxIOB for at få SMB\'er til at fungere fint! En god start er maxIOB=gennemsnitlig måltidsbolus + 3 x max daglig basal</string>
<string name="objectives_auto_gate">Læs dokumentationen om hvordan automatisering virker. Opsæt dine første enkle regler. I stedet for handling lad kun AAPS vise notifikation. Når du er sikker på, at automatisering udløses på det rigtige tidspunkt, skal du erstatte notifikationen med reel handling. (https://androidaps.readthedocs.io/en/latest/EN/Usage/Automation.html)</string>
<string name="objectives_bgavailableinns">BG tilgængelig i NS</string>
<string name="objectives_pumpstatusavailableinns">Pumpestatus tilgængelig i NS</string>
<string name="objectives_manualenacts">Manuelle handlinger</string>
<string name="accomplished">Udført: %1$s</string>
<string name="objectives_usage_objective">Lær at styre AndroidAPS</string>
<string name="objectives_usage_gate">Udfør forskellige handlinger i AndroidAPS</string>
<string name="objectives_useprofileswitch">Indstil profil til 90% i 10 min (Tryk og hold på profilnavn i Oversigt)</string>
<string name="objectives_usedisconnectpump">Simulér brusebad. Afbryd pumpen i 1t (Tryk og hold på Open Loop)</string>
<string name="objectives_usereconnectpump">... og genforbind på samme måde</string>
<string name="objectives_usetemptarget">Opret brugerdefinerede midlertidige mål med 10 min varighed (Tryk og hold på dit nuværende mål)</string>
<string name="objectives_useactions">I Konfigurations bygger, aktivér Handlings plugin, gør det synligt og vis dets indhold fra top menuen</string>
<string name="objectives_useloop">Vis indhold af Loop plugin</string>
<string name="objectives_usescale">Brug skala-funktion ved at trykke på BG-diagrammet længe</string>
<string name="objectives_button_enter">Indtast</string>
<string name="enter_code_obtained_from_developers_to_bypass_the_rest_of_objectives">Hvis du har mindst 3 måneders lukket loop erfaring med andre systemer, kan du kvalificere dig til en kode til at springe quizen over. Se https://androidaps.readthedocs.io/en/latest/EN/Usage/Objectives.html#skip-objectives for detaljer.</string>
<string name="codeaccepted">Kode accepteret</string>
<string name="codeinvalid">Kode ugyldig</string>
<string name="objectives_exam_objective">Bevis din viden</string>
<string name="objectives_exam_gate">Undersøg spørgsmålene. Du får fire mulige svar på hvert spørgsmål. Der kan være mere end et korrekt svar. Tjek alle dem, der er korrekte, og vælg GODKEND.</string>
<string name="answerdisabledto">Svar deaktiveret indtil: %1$s</string>
<string name="wronganswer">Forkert svar!</string>
<string name="unfinshed_button">Næste uafsluttede</string>
<string name="requestcode">Anmod om kode: %1$s</string>
<string name="objectives_hint">(tjek alle de korrekte svar)</string>
<string name="disconnectpump_hint" formatted="false">https://androidaps.readthedocs.io/en/latest/EN/Getting-Started/FAQ.html#what-to-do-when-taking-a-shower-or-bath</string>
<string name="usetemptarget_hint" formatted="false">https://androidaps.readthedocs.io/en/latest/EN/Getting-Started/Screenshots.html#the-homescreen</string>
<string name="useaction_hint" formatted="false">https://androidaps.readthedocs.io/en/latest/EN/Getting-Started/Screenshots.html#config-builder</string>
<string name="usescale_hint" formatted="false">https://androidaps.readthedocs.io/en/latest/EN/Getting-Started/Screenshots.html#the-homescreen</string>
<string name="notconnected">Ingen forbindelse til internettet</string>
<string name="failedretrievetime">Tid kunne ikke hentes</string>
<string name="requirementnotmet">Quiz krav ikke opfyldt</string>
</resources>

View file

@ -785,8 +785,31 @@
<string name="chartmenu">Diagrammenu</string>
<string name="loop_smbrequest_time_label">SMB anmodningstid</string>
<string name="loop_smbexecution_time_label">SMB udførelsestid</string>
<string name="loop_tbrrequest_time_label">Midlertidig basal anmodningstid</string>
<string name="loop_tbrexecution_time_label">Midlertidig basal afviklingstid</string>
<!-- SMS Communicator & OTP Authenticator -->
<string name="smscommunicator_code_from_authenticator_for" comment="This is continuation of sentence: To [ACTION] reply with code">fra Authenticator app til: %1$s efterfulgt af PIN</string>
<string name="smscommunicator_otp_pin">Yderligere obligatorisk pinkode i slutningen</string>
<string name="smscommunicator_otp_pin_summary">Yderligere cifre, der skal huskes og påsættes i slutningen af hver genereret engangsadgangskode</string>
<string name="smscomunicator_tab_otp_label">Authenticator opsætning</string>
<string name="smscommunicator_code_verify_label">Kode, der skal kontrolleres:</string>
<string name="smscommunicator_code_verify_hint">OTP + PIN</string>
<string name="smscommunicator_code_verify_info">Bekræftelseskoden består af 6 cifre som vises af Autentificerings-app (kendt som OTP) efterfulgt af 3 eller flere cifre i obligatorisk PIN-kode.</string>
<string name="smscommunicator_otp_reset_btn">Nulstil Autentificering</string>
<string name="smscommunicator_otp_reset_title">Nulstil Autentificeringsnøgle</string>
<string name="smscommunicator_otp_reset_prompt">Er du sikker på at du vil nulstille autentificeringsnøgle? Det vil gøre alle aktuelt konfigurerede autentificatorer ugyldige, og du bliver nødt til at sætte dem op igen.</string>
<string name="smscommunicator_otp_reset_successful">Ny autentificeringsnøgle blev genereret! Brug venligst opdateret QR kode til at levere autentificatorer.</string>
<string name="smscommunicator_otp_export_title">Eksporterer OTP hemmelighed</string>
<string name="smscommunicator_otp_export_prompt">Er du sikker på, at du vil kopiere OTP hemmelighed til udklipsholderen?\n\nDu behøver den kun, hvis din autentificeringsapp har problemer med at scanne QR kode, du vil indtaste den manuelt, eller du vil konfigurere hardware OTP token ved hjælp af en dedikeret app.</string>
<string name="smscommunicator_otp_export_successful">OTP hemmelige (i Base32 format) eksporteret og kopieret til udklipsholder. Indsæt det i autentifikatoren eller hardware OTP brænder!</string>
<string name="smscommunicator_otp_step1_install_header">1. Installer Authenticator</string>
<string name="smscommunicator_otp_step2_provisioning_header">2. Scan kode til opsætning af AndroidAPS OTP-koder</string>
<string name="smscommunicator_otp_step3_test_header">3. Test Engangsadgangskode</string>
<string name="smscommunicator_otp_reset_header">Nulstil Autentificering</string>
<string name="smscommunicator_otp_install_info">På hver follower telefon installeres Authenticator app, der understøtter RFC 6238 TOTP tokens. Populære gratis apps er:\n • Authy\n • Google Authenticator\n • LastPass Authenticator\n • FreeOTP Authenticator</string>
<string name="smscommunicator_otp_reset_warning">Ved at nulstille autentificering gør du alle allerede proviserede autentificatorer ugyldige. Du bliver nødt til at opsætte dem igen!</string>
<string name="overview_show_predictions">Forudsigelser</string>
<string name="overview_show_deviationslope">Afvigelses hældning</string>
<string name="authorizationfailed">Godkendelse mislykkedes</string>
<string name="overview_show_absinsulin">Absolut insulin</string>
<string name="master_password_summary">Hovedadgangskode bruges til backup kryptering og til at tilsidesætte sikkerhed i applikationen. Husk det eller gem et sikkert sted.</string>
@ -828,10 +851,58 @@
<string name="enablebolusreminder">Aktivér boluspåminder</string>
<string name="enablebolusreminder_summary">Brug påmindelse til bolus senere med guiden
(\"post-bolus\")</string>
<string name="time_to_bolus">Tid til bolus!\nKør Bolus-guiden og lav beregningen igen.</string>
<string name="fabric_upload_disabled">Upload af Crash logs deaktiveret!</string>
<string name="graph_menu_divider_header">Graf</string>
<string name="chart_menu">Diagrammenu</string>
<string name="clear_filter">Nulstil filter</string>
<string name="trend_arrow">Trend pil</string>
<string name="cannula">Kanyle</string>
<string name="userentry">Bruger indtastning</string>
<string name="common_values">Brug værdien af den største mængde mad du plejer at indtage\n</string>
<string name="summary_email_for_crash_report">Denne identifikation vil blive vedhæftet til nedbrudsrapporter, så vi kan kontakte dig i hastende tilfælde. Det er valgfrit.</string>
<string name="email_address">E-mail adresse</string>
<string name="privacy_settings">Indstillinger for privatliv</string>
<string name="privacy_summary">Du kan angive valgfri e-mail-adresse, hvis du ønsker at blive underrettet om app nedbrud. Dette er ikke en automatiseret tjeneste. Du vil blive kontaktet af udviklere i farlige situationer.</string>
<string name="full_sync">Fuld synkronisering</string>
<string name="full_sync_comment">Fuld synkronisering? Det kan tage mange timer, og indtil du er færdig, vil du ikke se nye data i NS.</string>
<string name="prime">Klargør</string>
<string name="ns_sync_options">Synkronisering</string>
<string name="ns_upload_summary">Profiler, bolusser, kulhydrater, midlertidige basaler uploades til NS</string>
<string name="ns_upload">Upload data til NS</string>
<string name="ns_receive_profile_store">Modtag profil lager</string>
<string name="ns_receive_profile_store_summary">Synkronisér profiler fra NS</string>
<string name="ns_receive_temp_target">Modtag midlertidige mål</string>
<string name="ns_receive_temp_target_summary">Accepter midlertidige mål indtastet gennem NS eller NSClient</string>
<string name="ns_receive_profile_switch">Modtag profil skift</string>
<string name="ns_receive_profile_switch_summary">Accepter profil skift indtastet gennem NS eller NSClient</string>
<string name="ns_receive_offline_event">Modtag APS offline begivenheder</string>
<string name="ns_receive_offline_event_summary">Accepter APS Offline begivenheder indtastet gennem NS eller NSClient</string>
<string name="ns_receive_insulin">Modtag insulin</string>
<string name="ns_receive_insulin_summary">Accepter insulin via NS eller NSClient (det er ikke afgivet, kun beregnet til IOB)</string>
<string name="ns_receive_carbs">Modtag kulhydrater</string>
<string name="ns_receive_carbs_summary">Accepter kulhydrater indtastet gennem NS eller NSClient</string>
<string name="ns_receive_therapy_events">Modtag behandlingshændelser</string>
<string name="ns_receive_therapy_events_summary">Accepter terapihændelser (Kanyle, insulin, batteriskift osv.), der indtastes gennem NS eller NSClient</string>
<string name="ns_receive_cgm">Modtag/tilbagefyld CGM-data</string>
<string name="ns_receive_cgm_summary">Accepter CGM-data fra NS</string>
<string name="sms_timeout_while_wating">Timeout mens du venter på afslutning af tidligere pumpe kommunikation</string>
<string name="smscommunicator_another_bolus_in_queue">Der er en anden bolus i kø. Prøv igen senere.</string>
<string name="calculation_in_progress">Beregning i gang</string>
<string name="missing_profile_name">Manglende profilnavn</string>
<string name="error_in_ic_values">Fejl i IC-værdier</string>
<string name="error_in_basal_values">Fejl i basal rate værdier</string>
<string name="error_in_target_values">Fejl i målværdier</string>
<string name="error_in_isf_values">Fejl i ISF-værdier</string>
<string name="run_question">Kør %s?</string>
<string name="invalid_profile_not_accepted">Ugyldig profil %1$s blev ikke accepteret fra NS</string>
<string name="view">Vis</string>
<string name="errors">Fejl</string>
<string name="ns_sync_slow">Reducer upload hastighed</string>
<string name="data_status">BG data status</string>
<string name="recalculated_data_used">Genberegnede data anvendt</string>
<string name="bg_too_close">BG for tæt:\n%1$s\n%2$s</string>
<string name="identification">Identifikation (e-mail, FB eller Discord alias osv.)</string>
<string name="identification_not_set">Identifikation ikke indstillet i udvikler-tilstand</string>
<string name="not_available_full">Ikke tilgængelig</string>
</resources>

View file

@ -720,7 +720,7 @@
<string name="old_version">versión antigua</string>
<string name="very_old_version">versión muy antigua</string>
<string name="application_expired">Aplicación caducada</string>
<string name="new_version_warning">Nueva versión disponible de al menos %1$d día/s. Soporte a función de suspensión por glucosa baja (LGS) durante %2$d días. Después se deshabilitará el lazo en %3$d días</string>
<string name="new_version_warning">Nueva versión disponible de al menos %1$d día/s. Soporte a la función de suspensión por glucosa baja (LGS) durante %2$d días. Después se deshabilitará el lazo en %3$d días</string>
<string name="twohours">2h</string>
<string name="dexcom_app_patched">Dexcom (BYODA)</string>
<string name="dexcom_short">BYODA</string>

View file

@ -882,7 +882,7 @@
<string name="ns_receive_insulin_summary">קבלת אינסולין שהוזן באמצעות נייטסקאוט או NSClient (הוא לא מוזרק, רק מחושב רק כאינסולין פעיל)</string>
<string name="ns_receive_carbs">קבלת פחמימות</string>
<string name="ns_receive_carbs_summary">קבלת פחמימות שנרשמו בנייטסקאוט או ב-NSClient</string>
<string name="ns_receive_therapy_events">קבלת אירועי טיפול</string>
<string name="ns_receive_therapy_events">קבל אירועי טיפול</string>
<string name="ns_receive_therapy_events_summary">קבלת אירועי טיפול (צינורית, אינסולין, החלפת סוללה) שצוינו באמצעות נייטסקאוט או NSClient</string>
<string name="ns_receive_cgm">קבלת\\טעינת נתוני סנסור</string>
<string name="ns_receive_cgm_summary">קבלת נתוני סנסור מנייטסקאוט</string>

View file

@ -173,7 +173,7 @@
<string name="ic_isf">프로파일에서 ISF를 바꾸면, I:C ratio도 항상 바꿔줘야 합니다.</string>
<string name="ic_label_exam">인슐린 대 탄수화물 비율 (I:C ratio)</string>
<string name="ic_increasingvalue">높은 I:C ratio은 탄수화물 섭취 시 인슐린을 적게 주입하게 합니다.</string>
<string name="ic_decreasingvalue">은 I:C ratio은 탄수화물 섭취 시 인슐린을 적게 주입하게 합니다.</string>
<string name="ic_decreasingvalue">은 I:C ratio은 탄수화물 섭취 시 인슐린을 적게 주입하게 합니다.</string>
<string name="ic_noeffect">COB가 0 인 경우 IC 비율을 변경하면 혈당을 교정하기 위해 다른 양의 인슐린이 주입됩니다.</string>
<string name="ic_different">Bread unit (교환 단위)를 10g 또는 12g으로 계산하면 IC 값도 달라지게 됩니다.</string>
<string name="ic_meaning">IC: 1U의 인슐린으로 bread uits (교환 단위)를 얼마나 섭취할 수 있는 지를 의미합니다.</string>

View file

@ -96,6 +96,7 @@
<string name="safety">Saugumas</string>
<string name="openapsma_disabled">Įskiepis išjungtas</string>
<string name="constraints_violation">Apribojimų pažeidimas</string>
<string name="treatmentdeliveryerror">Boluso suleidimo klaida. Rankiniu būdu patikrinkite faktiškai suleistą kiekį</string>
<string name="setbasalquestion">Patvirtinti naują laikiną bazę:</string>
<string name="overview_treatment_label">Terapija</string>
<string name="overview_calculator_label">Skaičiuotuvas</string>
@ -121,6 +122,7 @@
<string name="careportal_newnstreatment_other">Kiti</string>
<string name="careportal_newnstreatment_meter">Matuoklis</string>
<string name="careportal_newnstreatment_sensor">Sensorius</string>
<string name="carb_time_label">AV laikas</string>
<string name="careportal_newnstreatment_duration_label">Trukmė</string>
<string name="profile_label">Profilis</string>
<string name="careportal_newnstreatment_glucosetype">Gliukozės tipas</string>
@ -519,6 +521,8 @@
<string name="enablesmbwithhightemptarget_summary">Įjungti SMB, kai yra aktyvus aukštas tikslas (aktyvumas, daugiau nei 100 mg/dl arba 5,5 mmol/l)</string>
<string name="overview_insulin_label">Insulinas</string>
<string name="overview_buttons_selection">Mygtukai</string>
<string name="show_calibration_button_summary">Siunčia kalibravimą į xDrip+ arba atidaro modifikuotos Dexcom programos BYODA kalibravimo dialogą</string>
<string name="show_cgm_button_summary">Atidaro xDrip+ ar BYODA, o mygtukas ATGAL gražina į AAPS</string>
<string name="carb_increment_button_message">Paspaudus mygtuką įvedamas nustatytas angliavandenių kiekis</string>
<string name="insulin_increment_button_message">Paspaudus mygtuką įvedamas nustatytas insulino kiekis</string>
<string name="error_starting_cgm">Nepavyko paleisti NGJ programos. Įsitikinkite, kad ji įdiegta.</string>
@ -624,6 +628,7 @@
<string name="exitwizard">Praleisti sąrankos vedlį</string>
<string name="setupwizard_loop_description">Paspauskite mygtuką žemiau, norėdami leisti AndroidAPS patarti/atlikti bazės pakeitimus</string>
<string name="setupwizard_sensitivity_description">Jautrumo įskiepis yra naudojamas jautrumo aptikimui ir AAO skaičiavimams. Daugiau informacijos:</string>
<string name="setupwizard_sensitivity_url">https://androidaps.readthedocs.io/en/latest/Configuration/Sensitivity-detection-and-COB.html</string>
<string name="nsclientinfotext">NSClient palaiko ryšį su Nightscout. Jūs galite praleisti šią dalį dabar, bet negalėsite baigti mokymosi programos, kol nenustatysite ryšio su NS.</string>
<string name="diawarning">Atminkite: DKS profiliams reikia IVT bent 5 val. IVT = 5 - 6 val DKS profilyje atitinka IVT = 3 val sename (pompos terapijos) insulino profilyje.</string>
<string name="setupwizard_aps_description">Pasirinkite vieną iš esamų algoritmų. Jie yra išdėstyti nuo seniausio iki naujausio. Naujesni algoritmai yra galingesni ir agresyvesni. Taigi jei esate naujas vartotojas, geriau pradėti nuo AMA, o ne naujesnio. Nepamirškite perskaityti dokumentaciją ir sukonfigūruoti jį prieš naudojant.</string>
@ -635,6 +640,7 @@
<string name="needsystemwindowpermission">Norint gauti pranešimus, programai reikalingas sisteminio lango leidimas</string>
<string name="needlocationpermission">Programai reikia vietos nustatymo leidimo, kad būtų galima naudoti Bluetooth ir WiFi</string>
<string name="needstoragepermission">Aplikacijai reikia leidimo prieigai prie saugyklos, kad galėtų išsaugoti žurnalo įrašus ir eksportavimo nustatymus</string>
<string name="needconnectpermission">Programai reikalinga Bluetooth prieigos teisė</string>
<string name="request">Užklausa</string>
<string name="open_navigation">Atidaryti meniu</string>
<string name="close_navigation">Uždaryti meniu</string>
@ -644,6 +650,8 @@
<string name="time_elapsed">Praėjo laiko</string>
<string name="poctech">Poctech</string>
<string name="description_source_poctech">Gauti KG vertes iš Poctech programėlės</string>
<string name="glunovo">Glunovo</string>
<string name="description_source_glunovo">Gauti KG reikšmes iš Glunovo programos</string>
<string name="description_source_tomato">Gauti KG vertes iš Tomato programėlės (MiaoMiao)</string>
<string name="high_temptarget_raises_sensitivity_title">Intensyvus laikinas tikslas didina jautrumą</string>
<string name="high_temptarget_raises_sensitivity_summary"><![CDATA[Padidinti jautrumą laikiniems tikslams >= 100]]></string>
@ -672,6 +680,7 @@
<string name="resettodefaults">Atkurti numatytuosius</string>
<string name="nsmalfunction">NSClient sutrikimas. Reikėtų paleisti iš naujo NS ir NSClient.</string>
<string name="time_offset">Laiko poslinkis</string>
<string name="bolus_reminder">Priminti apie bolusą vėliau</string>
<string name="setupwizard_preferred_aps_mode">Pageidaujamas DKS režimas</string>
<string name="treatments_wizard_total_label">Viso</string>
<string name="calculation_short">Skaič.</string>
@ -713,6 +722,9 @@
<string name="application_expired">Aplikacijos laikas baigėsi</string>
<string name="new_version_warning">Nauja versija pasiekiama mažiausiai %1$d d.! Po %2$d grįšite prie stabdymo prie žemo, po %3$d ciklas bus išjungtas</string>
<string name="twohours">2 val</string>
<string name="dexcom_app_patched">BYODA</string>
<string name="dexcom_short">BYODA</string>
<string name="description_source_dexcom">Gauti kraujo gliukozės reikšmes iš \'Build Your Own Dexcom App\'.</string>
<string name="cobvsiob">AAO prieš AIO</string>
<string name="bolusconstraintappliedwarn">Pritaikytas boluso apribojimas: %1$.2f vv iki %2$.2f vv</string>
<string name="slowabsorptiondetected"><![CDATA[<font color=\'%1$s\'>!!!!! Nustatytas lėtas angliavandenių įsisavinimas: %2$d%% laiko. Dar karą patikrinkite savo skaičiavimus. AAO gali būti pervertinti, todėl gali būti suleista per daug insulino!!!!!</font>]]></string>
@ -835,6 +847,10 @@
<string name="enablebolusadvisor_summary">Galimybė priminti jums valgyti vėliau (pvz., esant aukštai glikemijai) boliuso vedlyje („po susileidimo palaukti ir valgyti vėliau“)</string>
<string name="time_to_eat">Laikas valgyti!\nĮjunkite Boluso patarėją ir atlikite skaičiavimą dar kartą.</string>
<string name="timetoeat">Laikas valgyti</string>
<string name="bolusreminder">Priminimas apie bolusą</string>
<string name="enablebolusreminder">Įgalinti priminimą apie bolusą</string>
<string name="enablebolusreminder_summary">Naudoti priminimus apie bolusą su skaičiuotuvu („post-bolusas“)</string>
<string name="time_to_bolus">Laikas bolusui!\nĮjunkite Skaičiuotuvą ir pakartokite skaičiavimus.</string>
<string name="fabric_upload_disabled">Sutrikimų žurnalo įrašų įkėlimas išjungtas!</string>
<string name="graph_menu_divider_header">Grafikas</string>
<string name="chart_menu">Grafiko meniu</string>
@ -843,6 +859,7 @@
<string name="cannula">Kaniulė</string>
<string name="userentry">Naudotojo įrašas</string>
<string name="common_values">Naudokite gausiausio patiekalo, kurį paprastai valgote, reikšmes\n</string>
<string name="summary_email_for_crash_report">Šis identifikatorius bus pridėtas prie gedimų ataskaitų, kad skubiais atvejais galėtume su jumis susisiekti. Jis neprivalomas.</string>
<string name="email_address">El. pašto adresas</string>
<string name="privacy_settings">Privatumo nuostatos</string>
<string name="privacy_summary">Nurodykite el. pašto adresą (neprivaloma), jei norite gauti informaciją apie programos strigimus. Tai nėra automatizuota paslauga. Kūrėjai susisieks esant pavojingoms situacijoms.</string>
@ -873,7 +890,18 @@
<string name="calculation_in_progress">Skaičiuojama</string>
<string name="missing_profile_name">Profilio pavadinimas nėra įrašytas</string>
<string name="error_in_ic_values">Insulino ir AV santykio (I:A) reikšmės klaida</string>
<string name="error_in_basal_values">Bazės reikšmių klaida</string>
<string name="error_in_target_values">Tikslinės glikemijos reikšmės klaida</string>
<string name="error_in_isf_values">JIF reikšmės klaida</string>
<string name="run_question">Vykdyti %s?</string>
<string name="invalid_profile_not_accepted">Neteisingas profilis %1$s nepriimtas iš NS</string>
<string name="view">Rodymas</string>
<string name="errors">Klaidos</string>
<string name="ns_sync_slow">Sulėtinti įkėlimus</string>
<string name="data_status">KG duomenų būklė</string>
<string name="recalculated_data_used">Naudojami perskaičiuoti duomenys</string>
<string name="bg_too_close">KG per arti:\n%1$s\n%2$s</string>
<string name="identification">Identifikacija (el. paštas, FB, Discord slapyvardis ar kt.)</string>
<string name="identification_not_set">Kūrėjo režime tapatybė nenustatyta</string>
<string name="not_available_full">Negalimas</string>
</resources>

View file

@ -132,6 +132,7 @@
<string name="wronginsulin_label">Erros de entrada/administração de insulina</string>
<string name="wronginsulin_whattodo">O que deve fazer se receber menos insulina do que o histórico da bomba sugere por exemplo devido a uma oclusão, uma cânula danificada ou esquecer-se de reanexar a bomba após um banho? </string>
<string name="wronginsulin_careportal">Elimine dados de insulina do Nightscout Careportal para removê-lo do histórico da bomba.</string>
<string name="wronginsulin_compare">Compare valores no AndroidAPS e no histórico da bomba.</string>
<string name="wronginsulin_prime">Bólus uma proporção de insulina calculada \'não administrada\' ou com seringa/caneta ou purgando.</string>
<string name="wronginsulin_donothing">Faça nada e permita que o AndroidAPS corrija qualquer nível de glicose elevado que daí resulte.</string>
<string name="iob_label">Insulina ativa (IA )</string>

View file

@ -96,6 +96,7 @@
<string name="safety">Segurança</string>
<string name="openapsma_disabled">Plugin está desativado</string>
<string name="constraints_violation">Violação das restrições</string>
<string name="treatmentdeliveryerror">Ocorreu um erro de bólus. Verifique manualmente a quantidade administrada</string>
<string name="setbasalquestion">Aceitar nova basal temporária:</string>
<string name="overview_treatment_label">Tratamento</string>
<string name="overview_calculator_label">Calculadora</string>
@ -520,6 +521,8 @@
<string name="enablesmbwithhightemptarget_summary">Activar SMB quando há alvo temporário elevado activo (exercício, acima de 100 mg/dl ou 5,5 mmol/l)</string>
<string name="overview_insulin_label">Bólus</string>
<string name="overview_buttons_selection">Botões</string>
<string name="show_calibration_button_summary">Envia a calibração para o xDrip+ ou abre o diálogo de calibração do BYODA</string>
<string name="show_cgm_button_summary">Abre xDrip+ ou BYODA, botão voltar retorna à AAPS</string>
<string name="carb_increment_button_message">Número de hidratos de carbono a adicionar quando o botão é premido</string>
<string name="insulin_increment_button_message">Unidades de insulina a adicionar quando o botão é premido</string>
<string name="error_starting_cgm">Não foi possível lançar aplicação de monitorização contínua. Por favor verifique que está instalada.</string>
@ -637,6 +640,7 @@
<string name="needsystemwindowpermission">Aplicação precisa de permissão de janela do sistema para notificações</string>
<string name="needlocationpermission">Aplicação necessita de permissão de localização para pesquisa Bluetooth e identificação Wi-Fi</string>
<string name="needstoragepermission">A aplicação precisa da permissão de armazenamento para poder armazenar ficheiros de registo e exportar definições</string>
<string name="needconnectpermission">Aplicação precisa de permissão Bluetooth</string>
<string name="request">Pedido</string>
<string name="open_navigation">Abrir a navegação</string>
<string name="close_navigation">Fechar a navegação</string>
@ -646,6 +650,8 @@
<string name="time_elapsed">Tempo decorrido</string>
<string name="poctech">Poctech</string>
<string name="description_source_poctech">Receber valores Glucose da app Poctech</string>
<string name="glunovo">Glunovo</string>
<string name="description_source_glunovo">Receber valores do aplicativo Glunovo</string>
<string name="description_source_tomato">Receber valores de Glicose da app Tomato (dispositivo MiaoMiao)</string>
<string name="high_temptarget_raises_sensitivity_title">Alto alvotempo aumenta sensibilidade</string>
<string name="high_temptarget_raises_sensitivity_summary"><![CDATA[Aumentar sensibilidade para alvostemp >= 100]]></string>
@ -716,6 +722,9 @@
<string name="application_expired">A aplicação expirou</string>
<string name="new_version_warning">Nova versão para pelo menos %1$d dias disponíveis! Retorno a SGB após %2$d dias, o loop será desactivado após %3$d dias</string>
<string name="twohours">2h</string>
<string name="dexcom_app_patched">BYODA</string>
<string name="dexcom_short">BYODA</string>
<string name="description_source_dexcom">Receber valores de glicemia do aplicativo BYODA.</string>
<string name="cobvsiob">HCA vs IA</string>
<string name="bolusconstraintappliedwarn">Restrição de bólus aplicada: %1$.2f U a %2$.2f U</string>
<string name="slowabsorptiondetected"><![CDATA[<font color=\'%1$s\'>!!!!! Absorção lenta de hidratos detetada: %2$d%% do tempo. Verifique o seu cálculo. HCA podem estar sobrestimados, assim mais insulina pode ser dada !!!</font>]]></string>
@ -839,6 +848,10 @@
<string name="time_to_eat">Hora de comer!\nExecutar assistente de Bólus e fazer cálculo novamente.</string>
<string name="timetoeat">Hora de comer</string>
<string name="bolusreminder">Lembrete de bólus</string>
<string name="enablebolusreminder">Ativar lembrete de bólus</string>
<string name="enablebolusreminder_summary">Usar lembrete para bólus mais tarde com o assistente
(\"pós-bólus\")</string>
<string name="time_to_bolus">Hora de fazer o bólus!\nExecute o assistente de bólus e faça o cálculo novamente.</string>
<string name="fabric_upload_disabled">Envio de registos de erro desativado!</string>
<string name="graph_menu_divider_header">Gráfico</string>
<string name="chart_menu">Menu do Gráfico</string>
@ -847,7 +860,49 @@
<string name="cannula">Cânula</string>
<string name="userentry">Entrada de Utilizador</string>
<string name="common_values">Utilize valores da sua maior refeição que normalmente come\n</string>
<string name="summary_email_for_crash_report">Esta identificação será anexada aos relatórios de erro para que possamos contatá-lo em casos urgentes. É opcional.</string>
<string name="email_address">Endereço de email</string>
<string name="privacy_settings">Definições de privacidade</string>
<string name="privacy_summary">Opcionalmente pode fornecer um endereço de e-mail se quiser ser notificado sobre os erros da app. Este não é um serviço automatizado. Será contactado por desenvolvedores em situações perigosas.</string>
<string name="full_sync">Sincronização completa</string>
<string name="full_sync_comment">Sincronização completa? Pode levar muitas horas até terminar e não irá ver dados novos no NS.</string>
<string name="prime">Purgar</string>
<string name="ns_sync_options">Sincronização</string>
<string name="ns_upload_summary">Perfil, bolus, hidratos de carbono e basais temporárias são enviados para o NS</string>
<string name="ns_upload">Enviar dados para o NS</string>
<string name="ns_receive_profile_store">Receber armazenamento de perfil</string>
<string name="ns_receive_profile_store_summary">Sincronizar perfis a partir do editor de perfis do NS</string>
<string name="ns_receive_temp_target">Receber alvos temporários</string>
<string name="ns_receive_temp_target_summary">Aceitar alvos temporários inseridos através do NS ou NSCliente</string>
<string name="ns_receive_profile_switch">Receber mudança de perfil</string>
<string name="ns_receive_profile_switch_summary">Aceitar mudanças de perfil inseridos através de NS ou NSCliente</string>
<string name="ns_receive_offline_event">Receber eventos da APS offline</string>
<string name="ns_receive_offline_event_summary">Aceitar eventos APS inseridos através de NS ou NSClient</string>
<string name="ns_receive_insulin">Receber insulina</string>
<string name="ns_receive_insulin_summary">Aceitar insulina inserida através do NS ou NSClient (não é administrada, apenas utilizada no cálculo da IA)</string>
<string name="ns_receive_carbs">Receber hidratos de carbono</string>
<string name="ns_receive_carbs_summary">Aceitar hidratos de carbono inseridos através do NS ou NSCliente</string>
<string name="ns_receive_therapy_events">Receber tratamentos</string>
<string name="ns_receive_therapy_events_summary">Aceitar tratamentos (catéter, insulina, mudança de bateria etc) inseridos através do NS ou NSCliente</string>
<string name="ns_receive_cgm">Receber/preencher dados do MCG</string>
<string name="ns_receive_cgm_summary">Aceitar dados do MCG provenientes do NS</string>
<string name="sms_timeout_while_wating">Tempo limite de espera para conclusão da comunicação com a bomba</string>
<string name="smscommunicator_another_bolus_in_queue">Existe outro bólus em espera. Tente novamente mais tarde.</string>
<string name="calculation_in_progress">Cálculo em curso</string>
<string name="missing_profile_name">Nome do perfil ausente</string>
<string name="error_in_ic_values">Erro nos valores de IHC</string>
<string name="error_in_basal_values">Erro nos valores da basal</string>
<string name="error_in_target_values">Erros no valor alvo</string>
<string name="error_in_isf_values">Erro nos valores do FSI</string>
<string name="run_question">Executar %s?</string>
<string name="invalid_profile_not_accepted">Perfil inválido %1$s não aceite do NS</string>
<string name="view">Ver</string>
<string name="errors">Erros</string>
<string name="ns_sync_slow">Reduzir velocidade de transferência</string>
<string name="data_status">Estado dos dados da Glicemia</string>
<string name="recalculated_data_used">Dados utilizados foram recalculados</string>
<string name="bg_too_close">Glicemia demasiado próxima:\n%1$s\n%2$s</string>
<string name="identification">Identificação (e-mail, nick FB ou Discord, etc)</string>
<string name="identification_not_set">Identificação não definida no modo desenvolvimento</string>
<string name="not_available_full">Indisponível</string>
</resources>

View file

@ -54,7 +54,7 @@
<string name="tempbasals_iob_label_string">IOB:</string>
<string name="tempbasals_iobtotal_label_string">Toplam IOB:</string>
<string name="treatments_wizard_bg_label"></string>
<string name="treatments_wizard_tt_label">TT</string>
<string name="treatments_wizard_tt_label">GH</string>
<string name="treatments_wizard_carbs_label">Karbonhidrat</string>
<string name="treatments_wizard_correction_label">Düzeltme</string>
<string name="bolus_iob_label">Bolus IOB</string>

View file

@ -1133,11 +1133,35 @@
<string name="errors">Errors</string>
<string name="ns_sync_slow">Slow down uploads</string>
<string name="data_status">BG data status</string>
<string name="statuslights_cannula_age">cannula age</string>
<string name="statuslights_patch_pump_age">patch pump age</string>
<string name="patch_pump">Patch pump</string>
<string name="recalculated_data_used">Recalculated data used</string>
<string name="bg_too_close">BG too close:\n%1$s\n%2$s</string>
<string name="key_last_processed_glunovo_timestamp" translatable="false">last_processed_glunovo_timestamp</string>
<string name="identification">Identification (email, FB or Discord nick etc)</string>
<string name="identification_not_set">Identification not set in dev mode</string>
<string name="a11y_high">heigh</string>
<string name="a11y_inrange">in range</string>
<string name="a11y_low">low</string>
<string name="a11y_arrow_double_down">down fast</string>
<string name="a11y_arrow_single_down">down</string>
<string name="a11y_arrow_forty_five_down">down trending</string>
<string name="a11y_arrow_flat">flat</string>
<string name="a11y_arrow_forty_five_up">up trending</string>
<string name="a11y_arrow_single_up">up</string>
<string name="a11y_arrow_double_up">up fast</string>
<string name="a11y_arrow_none">none</string>
<string name="a11y_arrow_unknown">unknown</string>
<string name="a11y_graph">graph</string>
<string name="a11y_bg_quality">Blood glucose quality</string>
<string name="a11_bg_quality_recalculated">recalculated</string>
<string name="a11_bg_quality_doubles">double entries</string>
<string name="a11y_insulin_label">insulin</string>
<string name="a11y_dialog">dialog</string>
<string name="a11y_current_bg">current blood glucode</string>
<string name="a11_correction_percentage">correct outcome with %</string>
<string name="a11_correction_units">correct outcome with units</string>
<string name="not_available_full">Not available</string>
</resources>

View file

@ -25,7 +25,7 @@
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:contentDescription="@string/action"
android:importantForAccessibility="no"
app:srcCompat="@drawable/ic_action_orange_48dp" />
<TextView

View file

@ -25,7 +25,7 @@
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:contentDescription="@string/please_choose_an_action_type"
android:importantForAccessibility="no"
app:srcCompat="@drawable/ic_action_orange_48dp" />
<TextView

View file

@ -25,7 +25,7 @@
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:contentDescription="@string/please_choose_a_operation_type"
android:importantForAccessibility="no"
app:srcCompat="@drawable/ic_trigger_green_48dp" />
<TextView

View file

@ -25,7 +25,7 @@
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:contentDescription="@string/please_choose_a_trigger_type"
android:importantForAccessibility="no"
app:srcCompat="@drawable/ic_trigger_green_48dp" />
<TextView

View file

@ -25,7 +25,7 @@
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:contentDescription="@string/triggers"
android:importantForAccessibility="no"
app:srcCompat="@drawable/ic_trigger_green_48dp" />
<TextView

View file

@ -25,7 +25,7 @@
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:contentDescription="@string/automation"
android:importantForAccessibility="no"
app:srcCompat="@drawable/ic_action_orange_48dp" />
<TextView

View file

@ -38,6 +38,9 @@
<string name="glucoseisnotavailable">Glicose não está disponível</string>
<string name="glucosecomparedmgdl">Glicose %1$s %2$.0f %3$s</string>
<string name="glucosecomparedmmol">Glicose %1$s %2$.1f %3$s</string>
<string name="notemptarget">Alvo temporário inexistente</string>
<string name="temptargetcomparedmgdl">Alvo Temporário %1$s %2$.0f %3$s</string>
<string name="temptargetcomparedmmol">Alvo Temporário %1$s %2$.1f %3$s</string>
<string name="percentagecompared">Percentagem Perfil %1$s %2$d</string>
<string name="iobcompared">IA %1$s %2$.1f</string>
<string name="and">E</string>
@ -86,6 +89,7 @@
<string name="latitude_short">Lat.:</string>
<string name="longitude_short">Long.:</string>
<string name="glucose_u">Glicose [%1$s]:</string>
<string name="target_u">Valor alvo [%1$s]:</string>
<string name="lastboluslabel">Último bolus atrás</string>
<string name="lastboluscompared">Última vez do bolus %1$s %2$s atrás</string>
<string name="triggercoblabel">HCA</string>
@ -101,9 +105,11 @@
<string name="edit_short">EDITAR</string>
<string name="please_choose_an_action_type">Escolha um tipo de acção</string>
<string name="please_choose_a_trigger_type">Escolha um tipo de condição</string>
<string name="please_choose_a_operation_type">Escolha um tipo de operação</string>
<string name="triggers">Condições:</string>
<string name="remove_label">REMOVER</string>
<string name="preconditions">Precondições:</string>
<string name="automation_event">Evento de automatização</string>
<string name="reorder_label">Reordenar</string>
<string name="user_action">Ação do utilizador</string>
</resources>

View file

@ -3,17 +3,17 @@
buildscript {
ext {
kotlin_version = '1.6.10'
coreVersion = '1.6.0'
core_version = '1.6.0'
rxjava_version = '2.2.21'
rxandroid_version = '2.1.1'
rxkotlin_version = '2.4.0'
room_version = '2.3.0'
lifecycle_version = '2.3.1'
dagger_version = '2.40.5'
coroutinesVersion = '1.4.1'
activityVersion = '1.3.1'
coroutines_version = '1.4.1'
activity_version = '1.3.1'
fragmentktx_version = '1.3.6'
ormLiteVersion = '4.46'
ormLite_version = '4.46'
nav_version = '2.3.5'
appcompat_version = '1.3.1'
material_version = '1.4.0'
@ -26,14 +26,14 @@ buildscript {
tink_version = '1.5.0'
junit_version = '4.13.2'
mockitoVersion = '4.3.1'
dexmakerVersion = "1.2"
retrofit2Version = '2.9.0'
okhttp3Version = '4.9.0'
byteBuddyVersion = '1.12.3'
mockito_version = '4.3.1'
dexmaker_version = "1.2"
retrofit2_version = '2.9.0'
okhttp3_version = '4.9.0'
byteBuddy_version = '1.12.3'
androidx_junit = '1.1.2'
androidx_rules = '1.4.0-alpha04'
androidx_junit_version = '1.1.2'
androidx_rules_version = '1.4.0'
timber_version = "4.7.1"
rxandroidble_version = '1.12.1'
@ -45,7 +45,7 @@ buildscript {
maven { url "https://plugins.gradle.org/m2/" } // jacoco 0.2
}
dependencies {
classpath 'com.android.tools.build:gradle:7.0.4'
classpath 'com.android.tools.build:gradle:7.1.1'
classpath 'com.google.gms:google-services:4.3.10'
classpath 'com.google.firebase:firebase-crashlytics-gradle:2.8.1'
@ -61,6 +61,7 @@ buildscript {
plugins {
id "io.gitlab.arturbosch.detekt" version "1.19.0"
id "org.jlleitschuh.gradle.ktlint" version "10.2.1"
id 'org.barfuin.gradle.jacocolog' version '2.0.0'
}
allprojects {
@ -90,6 +91,8 @@ allprojects {
}
}
apply from: 'gradle/jacoco_project.gradle'
task clean(type: Delete) {
delete rootProject.buildDir
}

View file

@ -22,7 +22,8 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"
@ -67,7 +68,8 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"
@ -113,7 +115,8 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"
@ -159,7 +162,8 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"
@ -204,7 +208,8 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"
@ -249,7 +254,8 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"
@ -294,7 +300,8 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"
@ -339,7 +346,8 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"
@ -384,7 +392,8 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"
@ -429,7 +438,8 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:orientation="horizontal"
android:focusable="true">
<TextView
android:layout_width="match_parent"

View file

@ -3,16 +3,16 @@ dependencies {
api "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version"
api "org.jetbrains.kotlin:kotlin-reflect:$kotlin_version"
api "org.jetbrains.kotlinx:kotlinx-coroutines-core:$coroutinesVersion"
api "org.jetbrains.kotlinx:kotlinx-coroutines-android:$coroutinesVersion"
api "androidx.core:core-ktx:$coreVersion"
api "org.jetbrains.kotlinx:kotlinx-coroutines-core:$coroutines_version"
api "org.jetbrains.kotlinx:kotlinx-coroutines-android:$coroutines_version"
api "androidx.core:core-ktx:$core_version"
api 'androidx.legacy:legacy-support-v13:1.0.0'
api 'androidx.legacy:legacy-support-v4:1.0.0'
api "androidx.appcompat:appcompat:$appcompat_version"
api "androidx.preference:preference-ktx:$preferencektx_version"
api 'androidx.biometric:biometric:1.1.0'
api "androidx.browser:browser:1.3.0"
api "androidx.activity:activity-ktx:${activityVersion}"
api "androidx.activity:activity-ktx:${activity_version}"
api "androidx.lifecycle:lifecycle-runtime-ktx:$lifecycle_version"
api 'androidx.cardview:cardview:1.0.0'
api 'androidx.recyclerview:recyclerview:1.2.1'
@ -47,8 +47,8 @@ dependencies {
api "com.jjoe64:graphview:4.0.1"
//db
api "com.j256.ormlite:ormlite-core:${ormLiteVersion}"
api "com.j256.ormlite:ormlite-android:${ormLiteVersion}"
api "com.j256.ormlite:ormlite-core:${ormLite_version}"
api "com.j256.ormlite:ormlite-android:${ormLite_version}"
// pumpCommon
api "com.google.code.gson:gson:2.8.7"
@ -65,11 +65,11 @@ dependencies {
api 'com.google.guava:listenablefuture:9999.0-empty-to-avoid-conflict-with-guava'
// new for tidepool
api "com.squareup.okhttp3:okhttp:$okhttp3Version"
api "com.squareup.okhttp3:logging-interceptor:$okhttp3Version"
api "com.squareup.retrofit2:retrofit:$retrofit2Version"
api "com.squareup.retrofit2:adapter-rxjava2:$retrofit2Version"
api "com.squareup.retrofit2:converter-gson:$retrofit2Version"
api "com.squareup.okhttp3:okhttp:$okhttp3_version"
api "com.squareup.okhttp3:logging-interceptor:$okhttp3_version"
api "com.squareup.retrofit2:retrofit:$retrofit2_version"
api "com.squareup.retrofit2:adapter-rxjava2:$retrofit2_version"
api "com.squareup.retrofit2:converter-gson:$retrofit2_version"
api "com.joanzapata.iconify:android-iconify-fontawesome:2.2.2"
api 'net.danlew:android.joda:2.10.6'

View file

@ -151,6 +151,7 @@ class ProfileViewerDialog : DaggerDialogFragment() {
binding.basalGraph.show(profile1, profile2)
binding.isfGraph.show(profile1, profile2)
binding.icGraph.show(profile1, profile2)
binding.targetGraph.show(profile1, profile2)
}
binding.noprofile.visibility = View.GONE
@ -171,6 +172,7 @@ class ProfileViewerDialog : DaggerDialogFragment() {
binding.basalGraph.show(it)
binding.isfGraph.show(it)
binding.icGraph.show(it)
binding.targetGraph.show(it)
binding.noprofile.visibility = View.GONE
val validity = it.isValid("ProfileViewDialog", activePlugin.activePump, config, rh, rxBus, hardLimits, false)

View file

@ -38,6 +38,7 @@ class PumpDescription() {
var supportsTDDs = false
var needsManualTDDLoad = false
var hasCustomUnreachableAlertCheck = false
var isPatchPump = false
fun resetSettings() {
isBolusCapable = true
@ -103,6 +104,7 @@ class PumpDescription() {
needsManualTDDLoad = pumpCapability.hasCapability(PumpCapability.ManualTDDLoad)
is30minBasalRatesCapable = pumpCapability.hasCapability(PumpCapability.BasalRate30min)
hasCustomUnreachableAlertCheck = pumpType.hasCustomUnreachableAlertCheck
isPatchPump = pumpType.isPatchPump
}
companion object {

View file

@ -43,7 +43,7 @@ public class AreaGraphSeries<E extends DoubleDataPoint> extends BaseSeries<E> {
/**
* the thickness of the line.
* This option will be ignored if you are
* using a custom paint via {@link #setCustomPaint(android.graphics.Paint)}
* using a custom paint via {@link #setCustomPaint(Paint)}
*/
private int thickness = 5;
@ -342,7 +342,7 @@ public class AreaGraphSeries<E extends DoubleDataPoint> extends BaseSeries<E> {
/**
* the thickness of the line.
* This option will be ignored if you are
* using a custom paint via {@link #setCustomPaint(android.graphics.Paint)}
* using a custom paint via {@link #setCustomPaint(Paint)}
*
* @return the thickness of the line
*/
@ -353,7 +353,7 @@ public class AreaGraphSeries<E extends DoubleDataPoint> extends BaseSeries<E> {
/**
* the thickness of the line.
* This option will be ignored if you are
* using a custom paint via {@link #setCustomPaint(android.graphics.Paint)}
* using a custom paint via {@link #setCustomPaint(Paint)}
*
* @param thickness thickness of the line
*/

View file

@ -184,6 +184,7 @@ enum class PumpType {
baseBasalSpecialSteps = null,
pumpCapability = PumpCapability.OmnipodCapabilities,
hasCustomUnreachableAlertCheck = true,
isPatchPump = true,
source = Sources.OmnipodEros),
OMNIPOD_DASH(description = "Omnipod Dash",
manufacturer = ManufacturerType.Insulet,
@ -198,6 +199,7 @@ enum class PumpType {
baseBasalMaxValue = null,
baseBasalStep = 0.05,
baseBasalSpecialSteps = null,
isPatchPump = true,
pumpCapability = PumpCapability.OmnipodCapabilities,
hasCustomUnreachableAlertCheck = false),
MEDTRONIC_512_712(description = "Medtronic 512/712",
@ -369,6 +371,8 @@ enum class PumpType {
private set
var hasCustomUnreachableAlertCheck = false
private set
var isPatchPump = false
private set
private var parent: PumpType? = null
val source: Sources
@ -437,6 +441,7 @@ enum class PumpType {
baseBasalSpecialSteps: DoseStepSize? = null,
pumpCapability: PumpCapability,
hasCustomUnreachableAlertCheck: Boolean = false,
isPatchPump: Boolean = false,
source: Sources = Sources.VirtualPump) {
this.description = description
this.manufacturer = manufacturer
@ -453,6 +458,7 @@ enum class PumpType {
this.baseBasalSpecialSteps = baseBasalSpecialSteps
this.pumpCapability = pumpCapability
this.hasCustomUnreachableAlertCheck = hasCustomUnreachableAlertCheck
this.isPatchPump = isPatchPump
this.source = source
}

View file

@ -6,6 +6,7 @@ import info.nightscout.androidaps.annotations.OpenForTesting
import info.nightscout.androidaps.core.R
import info.nightscout.androidaps.utils.resources.ResourceHelper
import info.nightscout.shared.SafeParse
import org.apache.commons.lang3.time.DateUtils.isSameDay
import org.joda.time.DateTime
import org.joda.time.format.DateTimeFormat
import org.joda.time.format.ISODateTimeFormat
@ -131,6 +132,10 @@ class DateUtil @Inject constructor(private val context: Context) {
return dateAndTimeString(start) + " - " + timeString(end)
}
fun timeRangeString(start: Long, end: Long): String {
return timeString(start) + " - " + timeString(end)
}
fun dateAndTimeString(mills: Long): String {
return if (mills == 0L) "" else dateString(mills) + " " + timeString(mills)
}
@ -207,6 +212,8 @@ class DateUtil @Inject constructor(private val context: Context) {
return TimeZone.getDefault().getOffset(timestamp) / 60000
}
fun isSameDay(timestamp1: Long, timestamp2: Long) = isSameDay(Date(timestamp1), Date(timestamp2))
//Map:{DAYS=1, HOURS=3, MINUTES=46, SECONDS=40, MILLISECONDS=0, MICROSECONDS=0, NANOSECONDS=0}
fun computeDiff(date1: Long, date2: Long): Map<TimeUnit, Long> {
val units: MutableList<TimeUnit> = ArrayList(EnumSet.allOf(TimeUnit::class.java))

View file

@ -2,12 +2,14 @@ package info.nightscout.androidaps.utils.ui
import android.content.Context
import android.util.AttributeSet
import com.jjoe64.graphview.DefaultLabelFormatter
import com.jjoe64.graphview.GraphView
import com.jjoe64.graphview.series.DataPoint
import com.jjoe64.graphview.series.LineGraphSeries
import info.nightscout.androidaps.core.R
import info.nightscout.androidaps.interfaces.Profile
import info.nightscout.androidaps.utils.Round
import java.text.NumberFormat
import java.util.ArrayList
import kotlin.math.max
@ -36,6 +38,10 @@ class BasalProfileGraph : GraphView {
viewport.setMaxY(Round.ceilTo(profile.getMaxDailyBasal() * 1.1, 0.5))
gridLabelRenderer.numHorizontalLabels = 13
gridLabelRenderer.verticalLabelsColor = basalSeries.color
val nf: NumberFormat = NumberFormat.getInstance()
nf.maximumFractionDigits = 1
gridLabelRenderer.setLabelFormatter(DefaultLabelFormatter(nf, nf))
}
fun show(profile1: Profile, profile2: Profile) {

View file

@ -2,12 +2,14 @@ package info.nightscout.androidaps.utils.ui
import android.content.Context
import android.util.AttributeSet
import com.jjoe64.graphview.DefaultLabelFormatter
import com.jjoe64.graphview.GraphView
import com.jjoe64.graphview.series.DataPoint
import com.jjoe64.graphview.series.LineGraphSeries
import info.nightscout.androidaps.core.R
import info.nightscout.androidaps.interfaces.Profile
import info.nightscout.androidaps.utils.Round
import java.text.NumberFormat
import java.util.*
import kotlin.math.max
@ -39,6 +41,10 @@ class IcProfileGraph : GraphView {
viewport.setMaxY(Round.ceilTo(maxIc * 1.1, 0.5))
gridLabelRenderer.numHorizontalLabels = 13
gridLabelRenderer.verticalLabelsColor = icSeries.color
val nf: NumberFormat = NumberFormat.getInstance()
nf.maximumFractionDigits = 1
gridLabelRenderer.setLabelFormatter(DefaultLabelFormatter(nf, nf))
}
fun show(profile1: Profile, profile2: Profile) {

View file

@ -2,13 +2,14 @@ package info.nightscout.androidaps.utils.ui
import android.content.Context
import android.util.AttributeSet
import com.jjoe64.graphview.DefaultLabelFormatter
import com.jjoe64.graphview.GraphView
import com.jjoe64.graphview.series.DataPoint
import com.jjoe64.graphview.series.LineGraphSeries
import info.nightscout.androidaps.core.R
import info.nightscout.androidaps.interfaces.Profile
import info.nightscout.androidaps.utils.Round
import java.util.ArrayList
import java.text.NumberFormat
import kotlin.math.max
class IsfProfileGraph : GraphView {
@ -31,15 +32,20 @@ class IsfProfileGraph : GraphView {
val isfSeries: LineGraphSeries<DataPoint> = LineGraphSeries(isfDataPoints)
addSeries(isfSeries)
isfSeries.thickness = 8
isfSeries.isDrawBackground = false
viewport.isXAxisBoundsManual = true
viewport.setMinX(0.0)
viewport.setMaxX(24.0)
viewport.isYAxisBoundsManual = true
viewport.setMinY(0.0)
viewport.setMaxY(Round.ceilTo(maxIsf * 1.1, 0.5))
val maxY = Round.ceilTo(maxIsf * 1.1, 0.5)
viewport.setMaxY(maxY)
gridLabelRenderer.numHorizontalLabels = 13
gridLabelRenderer.labelVerticalWidth = 40
gridLabelRenderer.verticalLabelsColor = isfSeries.color
val nf: NumberFormat = NumberFormat.getInstance()
nf.maximumFractionDigits = 1
gridLabelRenderer.setLabelFormatter(DefaultLabelFormatter(nf, nf))
}
fun show(profile1: Profile, profile2: Profile) {

View file

@ -15,6 +15,8 @@ import android.view.MotionEvent
import android.view.View
import android.view.View.OnFocusChangeListener
import android.view.View.OnTouchListener
import android.view.accessibility.AccessibilityEvent
import android.view.accessibility.AccessibilityManager
import android.view.inputmethod.InputMethodManager
import android.widget.Button
import android.widget.EditText
@ -50,6 +52,7 @@ open class NumberPicker(context: Context, attrs: AttributeSet? = null) : LinearL
protected var focused = false
private var mUpdater: ScheduledExecutorService? = null
private var mOnValueChangedListener: OnValueChangedListener? = null
private var mCustomContentDescription: String? = null
private var mHandler: Handler = Handler(Looper.getMainLooper(), Handler.Callback { msg: Message ->
when (msg.what) {
@ -86,6 +89,13 @@ open class NumberPicker(context: Context, attrs: AttributeSet? = null) : LinearL
}
}
var customContentDescription: String?
get() = mCustomContentDescription
set(value) {
mCustomContentDescription = value
updateA11yDescription()
}
protected open fun inflate(context: Context) {
LayoutInflater.from(context).inflate(R.layout.number_picker_layout, this, true)
}
@ -121,6 +131,29 @@ open class NumberPicker(context: Context, attrs: AttributeSet? = null) : LinearL
if (!focused) value // check min/max
updateEditText()
}
updateA11yDescription()
}
fun updateA11yDescription() {
val description = if (mCustomContentDescription != null) mCustomContentDescription else ""
minusButton?.contentDescription = context.getString(R.string.a11y_min_button_description, description, formatter?.format(this.step))
plusButton?.contentDescription = context.getString(R.string.a11y_plus_button_description, description, formatter?.format(this.step))
}
fun announceValue() {
val manager: AccessibilityManager = context
.getSystemService(Context.ACCESSIBILITY_SERVICE) as AccessibilityManager
if (manager.isEnabled) {
val valueDescription = formatter?.format(currentValue)
AccessibilityEvent.obtain().apply {
eventType = AccessibilityEvent.TYPE_ANNOUNCEMENT
className = javaClass.name
packageName = context.packageName
text.add(valueDescription)
}.also {
manager.sendAccessibilityEvent(it)
}
}
}
override fun setTag(tag: Any) {
@ -173,6 +206,7 @@ open class NumberPicker(context: Context, attrs: AttributeSet? = null) : LinearL
this.okButton = okButton
editText?.keyListener = DigitsKeyListenerWithComma.getInstance(minValue < 0, step != round(step))
if (watcher != null) editText?.removeTextChangedListener(watcher)
updateA11yDescription()
updateEditText()
if (watcher != null) editText?.addTextChangedListener(watcher)
}
@ -253,6 +287,7 @@ open class NumberPicker(context: Context, attrs: AttributeSet? = null) : LinearL
private fun stopUpdating() {
mUpdater?.shutdownNow()
mUpdater = null
announceValue()
}
override fun onClick(v: View) {
@ -265,6 +300,7 @@ open class NumberPicker(context: Context, attrs: AttributeSet? = null) : LinearL
} else {
dec(1)
}
announceValue()
}
}
@ -299,5 +335,16 @@ open class NumberPicker(context: Context, attrs: AttributeSet? = null) : LinearL
init {
initialize(context)
context.theme.obtainStyledAttributes(
attrs,
R.styleable.NumberPicker,
0, 0).apply {
try {
mCustomContentDescription = getString(R.styleable.NumberPicker_customContentDescription)
} finally {
recycle()
}
}
}
}
}

View file

@ -0,0 +1,99 @@
package info.nightscout.androidaps.utils.ui
import android.content.Context
import android.util.AttributeSet
import com.jjoe64.graphview.DefaultLabelFormatter
import com.jjoe64.graphview.GraphView
import info.nightscout.androidaps.core.R
import info.nightscout.androidaps.interfaces.GlucoseUnit
import info.nightscout.androidaps.interfaces.Profile
import info.nightscout.androidaps.utils.Round
import info.nightscout.androidaps.plugins.general.overview.graphExtensions.AreaGraphSeries
import info.nightscout.androidaps.plugins.general.overview.graphExtensions.DoubleDataPoint
import java.text.NumberFormat
import java.util.ArrayList
import kotlin.math.max
class TargetBgProfileGraph : GraphView {
constructor(context: Context?) : super(context)
constructor(context: Context?, attrs: AttributeSet?) : super(context, attrs)
fun show(profile: Profile) {
removeAllSeries()
val targetArray: MutableList<DoubleDataPoint> = ArrayList()
var maxValue = 0.0
val units = profile.units
for (hour in 0..23) {
val valueLow = Profile.fromMgdlToUnits(profile.getTargetLowMgdlTimeFromMidnight(hour * 60 * 60), units)
val valueHigh = Profile.fromMgdlToUnits(profile.getTargetHighMgdlTimeFromMidnight(hour * 60 * 60), units)
maxValue = max(maxValue, valueHigh)
targetArray.add(DoubleDataPoint(hour.toDouble(), valueLow, valueHigh))
targetArray.add(DoubleDataPoint((hour + 1).toDouble(), valueLow, valueHigh))
}
val targetDataPoints: Array<DoubleDataPoint> = Array(targetArray.size) { i -> targetArray[i] }
val targetSeries: AreaGraphSeries<DoubleDataPoint> = AreaGraphSeries(targetDataPoints)
addSeries(targetSeries)
targetSeries.isDrawBackground = true
viewport.isXAxisBoundsManual = true
viewport.setMinX(0.0)
viewport.setMaxX(24.0)
viewport.isYAxisBoundsManual = true
viewport.setMinY(0.0)
viewport.setMaxY(Round.ceilTo(maxValue * 1.1, 0.5))
gridLabelRenderer.numHorizontalLabels = 13
gridLabelRenderer.verticalLabelsColor = targetSeries.color
val nf: NumberFormat = NumberFormat.getInstance()
nf.maximumFractionDigits = if (units == GlucoseUnit.MMOL) 1 else 0
gridLabelRenderer.setLabelFormatter(DefaultLabelFormatter(nf, nf))
}
fun show(profile1: Profile, profile2: Profile) {
removeAllSeries()
val targetArray1: MutableList<DoubleDataPoint> = ArrayList()
var maxValue = 0.0
val units = profile1.units
for (hour in 0..23) {
val valueLow = Profile.fromMgdlToUnits(profile1.getTargetLowMgdlTimeFromMidnight(hour * 60 * 60), units)
val valueHigh = Profile.fromMgdlToUnits(profile1.getTargetHighMgdlTimeFromMidnight(hour * 60 * 60), units)
maxValue = max(maxValue, valueHigh)
targetArray1.add(DoubleDataPoint(hour.toDouble(), valueLow, valueHigh))
targetArray1.add(DoubleDataPoint((hour + 1).toDouble(), valueLow, valueHigh))
}
val targetDataPoints1: Array<DoubleDataPoint> = Array(targetArray1.size) { i -> targetArray1[i] }
val targetSeries1: AreaGraphSeries<DoubleDataPoint> = AreaGraphSeries(targetDataPoints1)
addSeries(targetSeries1)
targetSeries1.isDrawBackground = true
val targetArray2: MutableList<DoubleDataPoint> = ArrayList()
for (hour in 0..23) {
val valueLow = Profile.fromMgdlToUnits(profile2.getTargetLowMgdlTimeFromMidnight(hour * 60 * 60), units)
val valueHigh = Profile.fromMgdlToUnits(profile2.getTargetHighMgdlTimeFromMidnight(hour * 60 * 60), units)
maxValue = max(maxValue, valueHigh)
targetArray2.add(DoubleDataPoint(hour.toDouble(), valueLow, valueHigh))
targetArray2.add(DoubleDataPoint((hour + 1).toDouble(), valueLow, valueHigh))
}
val targetDataPoints2: Array<DoubleDataPoint> = Array(targetArray2.size) { i -> targetArray2[i] }
val targetSeries2: AreaGraphSeries<DoubleDataPoint> = AreaGraphSeries(targetDataPoints2)
addSeries(targetSeries2)
targetSeries2.isDrawBackground = false
targetSeries2.color = context.getColor(R.color.examinedProfile)
viewport.isXAxisBoundsManual = true
viewport.setMinX(0.0)
viewport.setMaxX(24.0)
viewport.isYAxisBoundsManual = true
viewport.setMinY(0.0)
viewport.setMaxY(Round.ceilTo(maxValue * 1.1, 0.5))
gridLabelRenderer.numHorizontalLabels = 13
gridLabelRenderer.verticalLabelsColor = targetSeries1.color
val nf: NumberFormat = NumberFormat.getInstance()
nf.maximumFractionDigits = if (units == GlucoseUnit.MMOL) 1 else 0
gridLabelRenderer.setLabelFormatter(DefaultLabelFormatter(nf, nf))
}
}

View file

@ -18,6 +18,7 @@
android:id="@+id/header_icon"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:importantForAccessibility="no"
app:srcCompat="@drawable/ic_trending_flat_white_48dp" />
<TextView

View file

@ -17,7 +17,7 @@
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:contentDescription="@string/error"
android:importantForAccessibility="no"
app:srcCompat="@drawable/ic_error_red_48dp" />
<TextView

Some files were not shown because too many files have changed in this diff Show more