2018-02-15 21:00:09 +01:00
|
|
|
<?xml version="1.0" encoding="utf-8"?>
|
|
|
|
|
|
|
|
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
|
|
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
|
|
|
xmlns:tools="http://schemas.android.com/tools"
|
|
|
|
android:layout_width="match_parent"
|
|
|
|
android:layout_height="match_parent"
|
|
|
|
tools:context="info.nightscout.androidaps.plugins.Overview.Dialogs.NewCarbsDialog">
|
|
|
|
|
|
|
|
<ScrollView
|
|
|
|
android:layout_width="match_parent"
|
|
|
|
android:layout_height="match_parent">
|
|
|
|
|
2018-04-04 19:59:16 +02:00
|
|
|
|
2018-02-15 21:00:09 +01:00
|
|
|
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
|
|
|
android:layout_width="wrap_content"
|
|
|
|
android:layout_height="wrap_content"
|
|
|
|
android:focusableInTouchMode="true"
|
|
|
|
android:orientation="vertical"
|
|
|
|
android:padding="10dp">
|
|
|
|
|
2018-04-04 19:59:16 +02:00
|
|
|
<LinearLayout
|
2018-05-13 13:34:39 +02:00
|
|
|
android:layout_width="wrap_content"
|
2018-04-04 19:59:16 +02:00
|
|
|
android:layout_height="wrap_content"
|
|
|
|
android:layout_gravity="center"
|
|
|
|
android:orientation="horizontal">
|
|
|
|
|
|
|
|
<ImageView
|
|
|
|
android:layout_width="wrap_content"
|
2018-05-13 13:34:39 +02:00
|
|
|
android:layout_height="wrap_content"
|
2018-04-04 19:59:16 +02:00
|
|
|
android:layout_gravity="center"
|
|
|
|
android:src="@drawable/icon_cp_bolus_carbs" />
|
|
|
|
|
|
|
|
<TextView
|
|
|
|
android:layout_width="wrap_content"
|
|
|
|
android:layout_height="wrap_content"
|
2018-05-13 13:34:39 +02:00
|
|
|
android:layout_gravity="center"
|
|
|
|
android:layout_marginLeft="10dp"
|
|
|
|
android:layout_marginRight="10dp"
|
2018-04-04 19:59:16 +02:00
|
|
|
android:text="@string/carbs"
|
2018-05-13 13:34:39 +02:00
|
|
|
android:textAppearance="?android:attr/textAppearanceLarge"
|
2018-04-04 19:59:16 +02:00
|
|
|
android:textColor="@color/colorCarbsButton" />
|
|
|
|
|
|
|
|
</LinearLayout>
|
2018-02-15 21:00:09 +01:00
|
|
|
|
2018-03-17 22:07:00 +01:00
|
|
|
<LinearLayout
|
2018-03-04 19:56:34 +01:00
|
|
|
android:layout_width="wrap_content"
|
2018-03-17 22:07:00 +01:00
|
|
|
android:layout_height="wrap_content"
|
|
|
|
android:layout_gravity="center_horizontal"
|
|
|
|
android:orientation="vertical">
|
2018-02-15 21:00:09 +01:00
|
|
|
|
2018-03-17 22:07:00 +01:00
|
|
|
<RadioButton
|
|
|
|
android:id="@+id/newcarbs_activity_tt"
|
|
|
|
android:layout_width="wrap_content"
|
|
|
|
android:layout_height="match_parent"
|
|
|
|
android:layout_marginTop="5dp"
|
|
|
|
android:text="@string/start_activity_tt" />
|
2018-02-15 21:00:09 +01:00
|
|
|
|
2018-03-17 22:07:00 +01:00
|
|
|
<RadioButton
|
|
|
|
android:id="@+id/newcarbs_eating_soon_tt"
|
|
|
|
android:layout_width="wrap_content"
|
|
|
|
android:layout_height="match_parent"
|
|
|
|
android:text="@string/start_eating_soon_tt" />
|
|
|
|
|
|
|
|
<RadioButton
|
|
|
|
android:id="@+id/newcarbs_hypo_tt"
|
|
|
|
android:layout_width="wrap_content"
|
|
|
|
android:layout_height="match_parent"
|
|
|
|
android:text="@string/start_hypo_tt" />
|
|
|
|
|
|
|
|
</LinearLayout>
|
2018-02-15 21:00:09 +01:00
|
|
|
|
2018-04-04 19:59:16 +02:00
|
|
|
<View
|
|
|
|
android:layout_width="fill_parent"
|
|
|
|
android:layout_height="2dip"
|
|
|
|
android:layout_marginBottom="5dp"
|
|
|
|
android:layout_marginTop="5dp"
|
|
|
|
android:background="@color/listdelimiter" />
|
|
|
|
|
|
|
|
<LinearLayout
|
|
|
|
android:layout_width="wrap_content"
|
|
|
|
android:layout_height="wrap_content"
|
|
|
|
android:paddingBottom="5dp"
|
|
|
|
android:paddingTop="5dp">
|
|
|
|
|
|
|
|
<TextView
|
|
|
|
android:layout_width="60dp"
|
|
|
|
android:layout_height="wrap_content"
|
|
|
|
android:layout_gravity="center_vertical"
|
2018-04-12 21:28:32 +02:00
|
|
|
android:textStyle="bold"
|
2018-08-03 13:04:58 +02:00
|
|
|
android:text="@string/time_offset" />
|
2018-04-04 19:59:16 +02:00
|
|
|
|
|
|
|
<info.nightscout.utils.NumberPicker
|
|
|
|
android:id="@+id/newcarbs_time"
|
|
|
|
android:layout_width="wrap_content"
|
|
|
|
android:layout_height="40dp"
|
|
|
|
android:layout_gravity="end"
|
|
|
|
android:paddingLeft="5dp"
|
|
|
|
android:paddingRight="5dp" />
|
|
|
|
|
|
|
|
<TextView
|
|
|
|
android:layout_width="wrap_content"
|
|
|
|
android:layout_height="wrap_content"
|
|
|
|
android:layout_gravity="center_vertical"
|
2018-04-12 21:28:32 +02:00
|
|
|
android:text="@string/shortminute" />
|
2018-04-04 19:59:16 +02:00
|
|
|
</LinearLayout>
|
|
|
|
|
|
|
|
<LinearLayout
|
|
|
|
android:id="@+id/newcarbs_duration_layout"
|
|
|
|
android:layout_width="wrap_content"
|
|
|
|
android:layout_height="wrap_content"
|
|
|
|
android:paddingTop="5dp"
|
|
|
|
android:paddingBottom="5dp">
|
|
|
|
|
|
|
|
<TextView
|
|
|
|
android:layout_width="60dp"
|
|
|
|
android:layout_height="wrap_content"
|
|
|
|
android:layout_gravity="center_vertical"
|
2018-04-12 21:28:32 +02:00
|
|
|
android:textStyle="bold"
|
|
|
|
android:text="@string/duration"/>
|
2018-04-04 19:59:16 +02:00
|
|
|
|
|
|
|
<info.nightscout.utils.NumberPicker
|
|
|
|
android:id="@+id/new_carbs_duration"
|
|
|
|
android:layout_width="wrap_content"
|
|
|
|
android:layout_height="40dp"
|
|
|
|
android:paddingLeft="5dp"
|
|
|
|
android:paddingRight="5dp"
|
|
|
|
android:layout_gravity="end" />
|
|
|
|
|
|
|
|
<TextView
|
|
|
|
android:layout_width="wrap_content"
|
|
|
|
android:layout_height="wrap_content"
|
|
|
|
android:layout_gravity="center_vertical"
|
2018-04-12 21:28:32 +02:00
|
|
|
android:text="@string/shorthour"/>
|
2018-04-04 19:59:16 +02:00
|
|
|
</LinearLayout>
|
|
|
|
|
|
|
|
<LinearLayout
|
|
|
|
android:layout_width="wrap_content"
|
|
|
|
android:layout_height="wrap_content"
|
|
|
|
android:paddingBottom="5dp"
|
|
|
|
android:paddingTop="5dp">
|
|
|
|
|
|
|
|
<TextView
|
|
|
|
android:layout_width="60dp"
|
|
|
|
android:layout_height="wrap_content"
|
|
|
|
android:layout_gravity="center_vertical"
|
2018-04-12 21:28:32 +02:00
|
|
|
android:textStyle="bold"
|
|
|
|
android:text="@string/overview_carbs_label" />
|
2018-04-04 19:59:16 +02:00
|
|
|
|
|
|
|
<info.nightscout.utils.NumberPicker
|
|
|
|
android:id="@+id/newcarb_carbsamount"
|
|
|
|
android:layout_width="wrap_content"
|
|
|
|
android:layout_height="40dp"
|
|
|
|
android:layout_gravity="end"
|
|
|
|
android:paddingLeft="5dp"
|
|
|
|
android:paddingRight="5dp" />
|
|
|
|
|
|
|
|
<TextView
|
|
|
|
android:layout_width="wrap_content"
|
|
|
|
android:layout_height="wrap_content"
|
|
|
|
android:layout_gravity="center_vertical"
|
2018-04-12 21:28:32 +02:00
|
|
|
android:text="@string/shortgramm" />
|
2018-04-04 19:59:16 +02:00
|
|
|
</LinearLayout>
|
2018-02-15 21:00:09 +01:00
|
|
|
|
|
|
|
<LinearLayout
|
|
|
|
android:layout_width="match_parent"
|
|
|
|
android:layout_height="match_parent"
|
2018-03-10 19:22:31 +01:00
|
|
|
android:layout_marginBottom="5dp"
|
|
|
|
android:orientation="horizontal">
|
2018-02-15 21:00:09 +01:00
|
|
|
|
|
|
|
<Button
|
|
|
|
android:id="@+id/newcarbs_plus1"
|
|
|
|
android:layout_width="match_parent"
|
|
|
|
android:layout_height="match_parent"
|
|
|
|
android:layout_weight="1"
|
|
|
|
android:text="+5" />
|
|
|
|
|
|
|
|
<Button
|
|
|
|
android:id="@+id/newcarbs_plus2"
|
|
|
|
android:layout_width="match_parent"
|
|
|
|
android:layout_height="match_parent"
|
|
|
|
android:layout_weight="1"
|
|
|
|
android:text="+10" />
|
|
|
|
|
|
|
|
<Button
|
|
|
|
android:id="@+id/newcarbs_plus3"
|
|
|
|
android:layout_width="match_parent"
|
|
|
|
android:layout_height="match_parent"
|
|
|
|
android:layout_weight="1"
|
|
|
|
android:text="+20" />
|
|
|
|
|
|
|
|
</LinearLayout>
|
|
|
|
|
2018-04-09 22:10:08 +02:00
|
|
|
<LinearLayout
|
2018-04-12 21:43:55 +02:00
|
|
|
android:id="@+id/newcarbs_notes_layout"
|
2018-04-09 22:10:08 +02:00
|
|
|
android:layout_width="match_parent"
|
|
|
|
android:layout_height="match_parent"
|
|
|
|
android:layout_marginBottom="5dp"
|
|
|
|
android:orientation="horizontal">
|
|
|
|
|
|
|
|
<TextView
|
2018-04-12 21:28:32 +02:00
|
|
|
android:layout_width="60dp"
|
2018-04-09 22:10:08 +02:00
|
|
|
android:layout_height="wrap_content"
|
2018-04-12 21:28:32 +02:00
|
|
|
android:layout_gravity="center_vertical"
|
2018-04-09 22:10:08 +02:00
|
|
|
android:width="60dp"
|
|
|
|
android:padding="2dp"
|
|
|
|
android:text="@string/careportal_newnstreatment_notes_label"
|
|
|
|
android:textAppearance="@android:style/TextAppearance.Material.Small"
|
|
|
|
android:textStyle="bold" />
|
|
|
|
|
|
|
|
<EditText
|
|
|
|
android:id="@+id/newcarbs_notes"
|
|
|
|
android:layout_width="match_parent"
|
2018-04-14 10:43:18 +02:00
|
|
|
android:layout_height="wrap_content"
|
2018-04-15 19:29:23 +02:00
|
|
|
android:inputType="text|textCapSentences" />
|
2018-04-09 22:10:08 +02:00
|
|
|
|
|
|
|
</LinearLayout>
|
|
|
|
|
2018-02-15 21:00:09 +01:00
|
|
|
<include layout="@layout/mdtp_done_button" />
|
|
|
|
|
|
|
|
</LinearLayout>
|
|
|
|
|
|
|
|
</ScrollView>
|
2018-04-09 22:10:08 +02:00
|
|
|
|
2018-03-04 19:56:34 +01:00
|
|
|
</FrameLayout>
|