AndroidAPS/app/src/main/res/layout/danar_user_options.xml
2019-03-22 23:08:13 +01:00

407 lines
18 KiB
XML

<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:focusable="true"
android:focusableInTouchMode="true"
tools:context=".plugins.pump.danaR.activities.DanaRUserOptionsActivity">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="match_parent">
<ScrollView
android:id="@+id/danar_user_options_view"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_above="@+id/danar_buttons"
android:fillViewport="true">
<LinearLayout
android:id="@+id/danar_user_options_top"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingBottom="10dp"
android:text="@string/danar_pump_settings"
android:textAlignment="center"
android:textAppearance="@style/TextAppearance.AppCompat.Large" />
<LinearLayout
android:id="@+id/overview_pumpstatuslayout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:paddingBottom="5dp"
android:paddingTop="2dp"
android:visibility="gone">
<TextView
android:id="@+id/overview_pumpstatus"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="5dp"
android:layout_marginRight="5dp"
android:gravity="center_vertical|center_horizontal"
android:text="@string/initializing"
android:textAppearance="?android:attr/textAppearanceSmall" />
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="5dp"
android:layout_marginEnd="20dp"
android:layout_marginLeft="20dp"
android:layout_marginRight="5dp"
android:layout_marginStart="20dp"
android:layout_marginTop="5dp"
android:orientation="horizontal">
<Switch
android:id="@+id/danar_timeformat"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
android:showText="true"
android:text="@string/danar_timedisplay"
android:textOff="12h"
android:textOn="24h" />
</LinearLayout>
<View
android:layout_width="fill_parent"
android:layout_height="2dip"
android:layout_marginBottom="5dp"
android:layout_marginLeft="20dp"
android:layout_marginRight="20dp"
android:layout_marginTop="5dp"
android:background="@color/listdelimiter" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="5dp"
android:layout_marginEnd="20dp"
android:layout_marginLeft="20dp"
android:layout_marginRight="5dp"
android:layout_marginStart="20dp"
android:layout_marginTop="5dp"
android:orientation="horizontal">
<Switch
android:id="@+id/danar_buttonscroll"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="@string/danar_buttonscroll"
android:textOff="@string/option_off"
android:textOn="@string/option_on" />
</LinearLayout>
<View
android:layout_width="fill_parent"
android:layout_height="2dip"
android:layout_marginBottom="5dp"
android:layout_marginLeft="20dp"
android:layout_marginRight="20dp"
android:layout_marginTop="5dp"
android:background="@color/listdelimiter" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="5dp"
android:layout_marginEnd="20dp"
android:layout_marginLeft="20dp"
android:layout_marginRight="5dp"
android:layout_marginStart="20dp"
android:layout_marginTop="5dp"
android:orientation="horizontal">
<Switch
android:id="@+id/danar_beep"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="@string/danar_beep"
android:textOff="@string/option_off"
android:textOn="@string/option_on" />
</LinearLayout>
<View
android:layout_width="fill_parent"
android:layout_height="2dip"
android:layout_marginBottom="5dp"
android:layout_marginLeft="20dp"
android:layout_marginRight="20dp"
android:layout_marginTop="5dp"
android:background="@color/listdelimiter" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="5dp"
android:layout_marginEnd="20dp"
android:layout_marginLeft="20dp"
android:layout_marginRight="5dp"
android:layout_marginStart="20dp"
android:layout_marginTop="5dp"
android:orientation="horizontal">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
android:gravity="left"
android:paddingRight="5dp"
android:text="@string/danar_pumpalarm"
android:textSize="14sp" />
<RadioGroup
android:id="@+id/danar_pumpalarm"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:checkedButton="@+id/danar_pumpalarm_sound">
<RadioButton
android:id="@+id/danar_pumpalarm_sound"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/danar_pumpalarm_sound" />
<RadioButton
android:id="@+id/danar_pumpalarm_vibrate"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/danar_pumpalarm_vibrate" />
<RadioButton
android:id="@+id/danar_pumpalarm_both"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/danar_pumpalarm_both" />
</RadioGroup>
</LinearLayout>
<View
android:layout_width="fill_parent"
android:layout_height="2dip"
android:layout_marginBottom="5dp"
android:layout_marginLeft="20dp"
android:layout_marginRight="20dp"
android:layout_marginTop="5dp"
android:background="@color/listdelimiter" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="5dp"
android:layout_marginEnd="20dp"
android:layout_marginLeft="20dp"
android:layout_marginRight="5dp"
android:layout_marginStart="20dp"
android:layout_marginTop="5dp"
android:gravity="center"
android:orientation="horizontal">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
android:gravity="top"
android:paddingRight="5dp"
android:text="@string/danar_screentimeout"
android:textSize="14sp" />
<info.nightscout.androidaps.utils.NumberPicker
android:id="@+id/danar_screentimeout"
android:layout_width="wrap_content"
android:layout_height="40dp"
android:layout_gravity="end"
android:paddingLeft="5dp"
android:paddingRight="5dp" />
</LinearLayout>
<View
android:layout_width="fill_parent"
android:layout_height="2dip"
android:layout_marginBottom="5dp"
android:layout_marginLeft="20dp"
android:layout_marginRight="20dp"
android:layout_marginTop="5dp"
android:background="@color/listdelimiter" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="5dp"
android:layout_marginEnd="20dp"
android:layout_marginLeft="20dp"
android:layout_marginRight="5dp"
android:layout_marginStart="20dp"
android:layout_marginTop="5dp"
android:gravity="center"
android:orientation="horizontal">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
android:gravity="top"
android:paddingRight="5dp"
android:text="@string/danar_backlight"
android:textSize="14sp" />
<info.nightscout.androidaps.utils.NumberPicker
android:id="@+id/danar_backlight"
android:layout_width="wrap_content"
android:layout_height="40dp"
android:layout_gravity="end"
android:paddingLeft="5dp"
android:paddingRight="5dp" />
</LinearLayout>
<View
android:layout_width="fill_parent"
android:layout_height="2dip"
android:layout_marginBottom="5dp"
android:layout_marginLeft="20dp"
android:layout_marginRight="20dp"
android:layout_marginTop="5dp"
android:background="@color/listdelimiter" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="5dp"
android:layout_marginEnd="20dp"
android:layout_marginLeft="20dp"
android:layout_marginRight="5dp"
android:layout_marginStart="20dp"
android:layout_marginTop="5dp"
android:orientation="horizontal">
<Switch
android:id="@+id/danar_units"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
android:showText="true"
android:splitTrack="false"
android:text="@string/danar_glucoseunits"
android:textOff="@string/mgdl"
android:textOn="@string/mmol" />
</LinearLayout>
<View
android:layout_width="fill_parent"
android:layout_height="2dip"
android:layout_marginBottom="5dp"
android:layout_marginLeft="20dp"
android:layout_marginRight="20dp"
android:layout_marginTop="5dp"
android:background="@color/listdelimiter" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="5dp"
android:layout_marginEnd="20dp"
android:layout_marginLeft="20dp"
android:layout_marginRight="5dp"
android:layout_marginStart="20dp"
android:layout_marginTop="5dp"
android:gravity="center"
android:orientation="horizontal">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
android:gravity="left"
android:paddingRight="5dp"
android:text="@string/danar_shutdown"
android:textSize="14sp" />
<info.nightscout.androidaps.utils.NumberPicker
android:id="@+id/danar_shutdown"
android:layout_width="wrap_content"
android:layout_height="40dp"
android:layout_gravity="end"
android:paddingLeft="5dp"
android:paddingRight="5dp" />
</LinearLayout>
<View
android:layout_width="fill_parent"
android:layout_height="2dip"
android:layout_marginBottom="5dp"
android:layout_marginLeft="20dp"
android:layout_marginRight="20dp"
android:layout_marginTop="5dp"
android:background="@color/listdelimiter" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="5dp"
android:layout_marginEnd="20dp"
android:layout_marginLeft="20dp"
android:layout_marginRight="5dp"
android:layout_marginStart="20dp"
android:layout_marginTop="5dp"
android:gravity="center"
android:orientation="horizontal">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
android:gravity="left"
android:paddingRight="5dp"
android:text="@string/danar_lowreservoir"
android:textSize="14sp" />
<info.nightscout.androidaps.utils.NumberPicker
android:id="@+id/danar_lowreservoir"
android:layout_width="wrap_content"
android:layout_height="40dp"
android:layout_gravity="end"
android:paddingLeft="5dp"
android:paddingRight="5dp" />
</LinearLayout>
<Button
android:id="@+id/save_user_options"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:text="@string/danar_saveuseroptions" />
</LinearLayout>
</ScrollView>
</RelativeLayout>
</FrameLayout>