Merge pull request #210 from nightscout/fix/concurrent-button-press-crash

Fix/concurrent button press crash
This commit is contained in:
Milos Kozak 2021-01-10 19:52:04 +01:00 committed by GitHub
commit a843bb8b84
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -372,6 +372,7 @@ public class TimeListEdit {
}
private void addItem(int index, int timeAsSeconds, double value1, double value2) {
if (itemsCount() >= 24) return;
if (itemsCount() > inflatedUntil) {
layout.removeView(finalAdd);
inflateRow(++inflatedUntil);