From e895ba65eb7c223b2473c52b6f6c63df22d095c4 Mon Sep 17 00:00:00 2001 From: Johannes Mockenhaupt Date: Thu, 26 Oct 2017 01:05:52 +0200 Subject: [PATCH] KeepAliveReceiver: proper Notification ids. --- .../nightscout/androidaps/plugins/Overview/Notification.java | 4 +++- .../nightscout/androidaps/receivers/KeepAliveReceiver.java | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/app/src/main/java/info/nightscout/androidaps/plugins/Overview/Notification.java b/app/src/main/java/info/nightscout/androidaps/plugins/Overview/Notification.java index 037018864e..a5614402b0 100644 --- a/app/src/main/java/info/nightscout/androidaps/plugins/Overview/Notification.java +++ b/app/src/main/java/info/nightscout/androidaps/plugins/Overview/Notification.java @@ -51,7 +51,9 @@ public class Notification { public static final int TOAST_ALARM = 22; public static final int WRONGBASALSTEP = 23; public static final int BOLUS_DELIVERY_ERROR = 24; - public static final int COMBO_PUMP_ERROR = 25; + public static final int COMBO_PUMP_ALARM = 25; + public static final int PUMP_UNREACHABLE = 26; + public static final int BG_READINGS_MISSED = 27; public int id; public Date date; diff --git a/app/src/main/java/info/nightscout/androidaps/receivers/KeepAliveReceiver.java b/app/src/main/java/info/nightscout/androidaps/receivers/KeepAliveReceiver.java index 967da79455..03610d3a2d 100644 --- a/app/src/main/java/info/nightscout/androidaps/receivers/KeepAliveReceiver.java +++ b/app/src/main/java/info/nightscout/androidaps/receivers/KeepAliveReceiver.java @@ -47,7 +47,7 @@ public class KeepAliveReceiver extends BroadcastReceiver { private void checkBg() { BgReading bgReading = DatabaseHelper.lastBg(); if (bgReading != null && bgReading.date + 25 * 60 * 1000 < System.currentTimeMillis()) { - Notification n = new Notification(Notification.PUMP_UNREACHABLE, "Missed BG readings", Notification.URGENT); + Notification n = new Notification(Notification.BG_READINGS_MISSED, "Missed BG readings", Notification.URGENT); n.soundId = R.raw.alarm; MainApp.bus().post(new EventNewNotification(n)); }