Add headers to dialogs.

This commit is contained in:
Johannes Mockenhaupt 2017-11-21 00:21:56 +01:00
parent 75855f3f05
commit 1b50b43fbb
No known key found for this signature in database
GPG key ID: 9E1EA6AF7BBBB0D1
5 changed files with 70 additions and 12 deletions

View file

@ -1,6 +1,7 @@
- [ ] Bugs
- [ ] Taking over benign warnings on connect doesn't work properly
(Notification raised but not confirmed?)
- [ ] Reading full history multiple times duplicates entries shown in Stats/TDD dialog
- [x] ruffy: Accessing the quick info menu yields noMenu when cartridge is low
- [x] ruffy: Multi-digit error codes in error history aren't supported
- [-] No connection can be established anymore; ruffy issue i can't solve

View file

@ -226,6 +226,7 @@ public class ComboPlugin implements PluginBase, PumpInterface, ConstraintsInterf
}
CommandResult commandResult = runCommand(MainApp.sResources.getString(R.string.combo_activity_setting_basal_profile), 2,
() -> ruffyScripter.setBasalProfile(basalProfile));
// Note: no verification here, command checks summary of inputs (total basal) at the end
return commandResult.success ? PumpInterface.SUCCESS : PumpInterface.FAILED;*/
}

View file

@ -4,6 +4,32 @@
android:layout_height="match_parent"
tools:context=".plugins.PumpCombo.ComboFragment">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<TextView
android:id="@+id/textView3"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal"
android:gravity="center_horizontal"
android:layout_marginTop="5dp"
android:text="Alerts"
android:textStyle="bold" />
<View
android:id="@+id/profileview_datedelimiter"
android:layout_width="match_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" />
<ScrollView
android:layout_width="match_parent"
android:layout_height="match_parent">
@ -24,4 +50,6 @@
</ScrollView>
</LinearLayout>
</FrameLayout>

View file

@ -4,24 +4,52 @@
android:layout_height="match_parent"
tools:context=".plugins.PumpCombo.ComboFragment">
<ScrollView
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent">
android:layout_height="match_parent"
android:orientation="vertical">
<LinearLayout
<TextView
android:id="@+id/textView3"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
android:layout_gravity="center_horizontal"
android:gravity="center_horizontal"
android:layout_marginTop="5dp"
android:text="TDD"
android:textStyle="bold" />
<TextView
android:id="@+id/combo_tdd_history_text"
<View
android:id="@+id/profileview_datedelimiter"
android:layout_width="match_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" />
<ScrollView
android:layout_width="match_parent"
android:layout_height="match_parent">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:textAlignment="textStart"
android:padding="10dp"
android:gravity="start"/>
</LinearLayout>
android:orientation="vertical">
<TextView
android:id="@+id/combo_tdd_history_text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="start"
android:padding="10dp"
android:textAlignment="textStart" />
</LinearLayout>
</ScrollView>
</LinearLayout>
</ScrollView>
</FrameLayout>

View file

@ -19,7 +19,7 @@ public class Tdd extends HistoryRecord {
Tdd tdd = (Tdd) o;
if (timestamp != tdd.timestamp) return false;
return Math.abs(tdd.total - total) <= 0.05;
return tdd.total != total;
}
@Override