AndroidAPS/app/src/main/res/layout/dialog_profileswitch.xml
2022-04-19 13:23:35 +02:00

236 lines
9.1 KiB
XML

<?xml version="1.0" encoding="utf-8"?>
<ScrollView 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"
style="@style/StyleDialog"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:focusableInTouchMode="true"
tools:context=".dialogs.ProfileSwitchDialog">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
<RelativeLayout
style="@style/StyleDialogHeader"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center">
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:importantForAccessibility="no"
app:srcCompat="@drawable/ic_actions_profileswitch" />
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_centerInParent="true"
android:layout_gravity="center"
android:layout_marginStart="10dp"
android:layout_marginEnd="10dp"
android:text="@string/careportal_profileswitch"
android:textAlignment="center"
android:textAppearance="?android:attr/textAppearanceLarge" />
</RelativeLayout>
<LinearLayout
android:id="@+id/spacer"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:padding="5dp" />
<com.google.android.material.textfield.TextInputLayout
style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox.ExposedDropdownMenu"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="5dp"
android:layout_marginEnd="5dp"
android:hint="@string/profile">
<com.google.android.material.textfield.MaterialAutoCompleteTextView
android:id="@+id/profileList"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:inputType="none" />
</com.google.android.material.textfield.TextInputLayout>
<LinearLayout
android:id="@+id/reuselayout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center_horizontal"
android:orientation="horizontal"
android:visibility="gone">
<info.nightscout.androidaps.utils.ui.SingleClickButton
android:id="@+id/reusebutton"
style="@style/ButtonSmallFontStyle"
android:drawablePadding="10dp"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:drawableStart="@drawable/ic_clone" />
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingTop="5dp"
android:orientation="horizontal">
<TextView
android:id="@+id/duration_label"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:width="120dp"
android:paddingStart="10dp"
android:paddingEnd="10dp"
android:text="@string/careportal_newnstreatment_duration_label"
android:textAppearance="@style/TextAppearance.AppCompat.Small"
android:textStyle="bold" />
<info.nightscout.androidaps.utils.ui.MinutesNumberPicker
android:id="@+id/duration"
android:layout_width="130dp"
android:layout_height="40dp"
android:layout_marginBottom="2dp"
app:customContentDescription="@string/careportal_newnstreatment_duration_label" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:gravity="start"
android:minWidth="45dp"
android:paddingStart="5dp"
android:paddingEnd="5dp"
android:text="@string/unit_minute_short"
android:textAppearance="?android:attr/textAppearanceSmall" />
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<TextView
android:id="@+id/percentage_label"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:width="120dp"
android:paddingStart="10dp"
android:paddingEnd="10dp"
android:text="@string/careportal_newnstreatment_percentage_label"
android:textAppearance="@style/TextAppearance.AppCompat.Small"
android:textStyle="bold" />
<info.nightscout.androidaps.utils.ui.NumberPicker
android:id="@+id/percentage"
android:layout_width="130dp"
android:layout_height="40dp"
android:layout_marginBottom="2dp"
app:customContentDescription="@string/careportal_newnstreatment_percentage_label" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:gravity="start"
android:minWidth="45dp"
android:paddingStart="5dp"
android:paddingEnd="5dp"
android:text="%"
android:textAppearance="?android:attr/textAppearanceSmall"
tools:ignore="HardcodedText" />
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<TextView
android:id="@+id/timeshift_label"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:width="120dp"
android:paddingStart="10dp"
android:paddingEnd="10dp"
android:text="@string/careportal_newnstreatment_timeshift_label"
android:textAppearance="@style/TextAppearance.AppCompat.Small"
android:textStyle="bold" />
<info.nightscout.androidaps.utils.ui.NumberPicker
android:id="@+id/timeshift"
android:layout_width="130dp"
android:layout_height="40dp"
app:customContentDescription="@string/careportal_newnstreatment_timeshift_label"/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:gravity="start"
android:minWidth="45dp"
android:paddingStart="5dp"
android:paddingEnd="5dp"
android:text="@string/unit_hours"
android:textAppearance="?android:attr/textAppearanceSmall" />
</LinearLayout>
<LinearLayout
android:id="@+id/tt_layout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:width="120dp"
android:paddingStart="10dp"
android:paddingEnd="10dp"
android:text="@string/careportal_temporarytarget"
android:textAppearance="@style/TextAppearance.AppCompat.Small"
android:textStyle="bold" />
<CheckBox
android:id="@+id/tt"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:layout_weight="1"
android:text="@string/activity" />
</LinearLayout>
<include
android:id="@+id/notes_layout"
layout="@layout/notes" />
<include
android:id="@+id/datetime"
layout="@layout/datetime" />
<include
android:id="@+id/okcancel"
layout="@layout/okcancel" />
</LinearLayout>
</ScrollView>