From 3aaca99d7f5471498af04f066a4c9e6553630d9d Mon Sep 17 00:00:00 2001 From: Andrei Vereha Date: Sun, 22 May 2022 12:45:26 +0200 Subject: [PATCH] remove automatic TZ change --- .../omnipod/dash/OmnipodDashPumpPlugin.kt | 25 +------------------ .../main/res/xml/omnipod_dash_preferences.xml | 12 --------- 2 files changed, 1 insertion(+), 36 deletions(-) diff --git a/omnipod-dash/src/main/java/info/nightscout/androidaps/plugins/pump/omnipod/dash/OmnipodDashPumpPlugin.kt b/omnipod-dash/src/main/java/info/nightscout/androidaps/plugins/pump/omnipod/dash/OmnipodDashPumpPlugin.kt index 8ee3f6d193..a7572cf244 100644 --- a/omnipod-dash/src/main/java/info/nightscout/androidaps/plugins/pump/omnipod/dash/OmnipodDashPumpPlugin.kt +++ b/omnipod-dash/src/main/java/info/nightscout/androidaps/plugins/pump/omnipod/dash/OmnipodDashPumpPlugin.kt @@ -1296,30 +1296,7 @@ class OmnipodDashPumpPlugin @Inject constructor( } override fun timezoneOrDSTChanged(timeChangeType: TimeChangeType) { - val eventHandlingEnabled = sp.getBoolean(R.string.key_omnipod_common_time_change_event_enabled, false) - - aapsLogger.info( - LTag.PUMP, - "Time, Date and/or TimeZone changed. [timeChangeType=" + timeChangeType.name + ", eventHandlingEnabled=" + eventHandlingEnabled + "]" - ) - - when { - !eventHandlingEnabled -> { - aapsLogger.info(LTag.PUMP, "Ignoring time change because automatic time handling is disabled in configuration") - return - } - timeChangeType == TimeChangeType.TimeChanged -> { - aapsLogger.info(LTag.PUMP, "Ignoring time change because it is not a DST or TZ change") - return - } - !podStateManager.isPodRunning -> { - aapsLogger.info(LTag.PUMP, "Ignoring time change because no Pod is active") - return - } - } - aapsLogger.info(LTag.PUMP, "Handling time change") - - commandQueue.customCommand(CommandHandleTimeChange(false), null) + aapsLogger.info(LTag.PUMP, "Ignoring time change because automatic time handling is not implemented. timeChangeType=${timeChangeType.name}") } private fun executeProgrammingCommand( diff --git a/omnipod-dash/src/main/res/xml/omnipod_dash_preferences.xml b/omnipod-dash/src/main/res/xml/omnipod_dash_preferences.xml index e53a64c3ac..4ac7f901be 100644 --- a/omnipod-dash/src/main/res/xml/omnipod_dash_preferences.xml +++ b/omnipod-dash/src/main/res/xml/omnipod_dash_preferences.xml @@ -99,16 +99,4 @@ android:title="@string/omnipod_common_preferences_notification_delivery_suspended_sound_enabled" /> - - - - - - \ No newline at end of file