From 77a34518bc3e61d6c391b641e80000b4e6b137c5 Mon Sep 17 00:00:00 2001 From: sawinglogz <3787776-sawinglogz@users.noreply.gitlab.com> Date: Mon, 23 Mar 2020 13:07:08 -0400 Subject: [PATCH] Rename PRS1 mask resistance lock and setting channels for clarity. --- oscar/SleepLib/loader_plugins/prs1_loader.cpp | 26 +++++++++---------- oscar/SleepLib/machine_common.cpp | 5 ++-- oscar/SleepLib/machine_common.h | 5 ++-- oscar/tests/sessiontests.cpp | 4 +-- 4 files changed, 19 insertions(+), 21 deletions(-) diff --git a/oscar/SleepLib/loader_plugins/prs1_loader.cpp b/oscar/SleepLib/loader_plugins/prs1_loader.cpp index c5468706..aa576c35 100644 --- a/oscar/SleepLib/loader_plugins/prs1_loader.cpp +++ b/oscar/SleepLib/loader_plugins/prs1_loader.cpp @@ -4222,7 +4222,7 @@ bool PRS1Import::ImportCompliance() session->settings[PRS1_HumidLevel] = e->m_value; break; case PRS1_SETTING_MASK_RESIST_LOCK: - session->settings[PRS1_SysLock] = (bool) e->m_value; + session->settings[PRS1_MaskResistLock] = (bool) e->m_value; break; case PRS1_SETTING_MASK_RESIST_SETTING: // Don't bother importing these for bricks, because they're always locked off. @@ -7548,10 +7548,10 @@ bool PRS1Import::ImportSummary() session->settings[PRS1_HumidLevel] = e->m_value; break; case PRS1_SETTING_MASK_RESIST_LOCK: - session->settings[PRS1_SysLock] = (bool) e->m_value; + session->settings[PRS1_MaskResistLock] = (bool) e->m_value; break; case PRS1_SETTING_MASK_RESIST_SETTING: - session->settings[PRS1_SysOneResistSet] = e->m_value; + session->settings[PRS1_MaskResistSet] = e->m_value; break; case PRS1_SETTING_HOSE_DIAMETER: session->settings[PRS1_HoseDiam] = e->m_value; @@ -8712,11 +8712,11 @@ void PRS1Loader::initChannels() chan->addOption(4, QObject::tr("4")); chan->addOption(5, QObject::tr("5")); - channel.add(GRP_CPAP, chan = new Channel(PRS1_SysOneResistSet = 0xe104, SETTING, MT_CPAP, SESSION, - "SysOneResistSet", - QObject::tr("System One Resistance Setting"), - QObject::tr("System One Mask Resistance Setting"), - QObject::tr("Sys1 Resist. Set"), + channel.add(GRP_CPAP, chan = new Channel(PRS1_MaskResistSet = 0xe104, SETTING, MT_CPAP, SESSION, + "MaskResistSet", + QObject::tr("Mask Resistance Setting"), + QObject::tr("Mask Resistance Setting"), + QObject::tr("Mask Resist."), "", LOOKUP, Qt::green)); chan->addOption(0, STR_TR_Off); chan->addOption(1, QObject::tr("x1")); @@ -8744,11 +8744,11 @@ void PRS1Loader::initChannels() chan->addOption(0, STR_TR_Off); chan->addOption(1, STR_TR_On); - channel.add(GRP_CPAP, chan = new Channel(PRS1_SysLock = 0xe108, SETTING, MT_CPAP, SESSION, - "SysOneLock", - QObject::tr("System One Resistance Lock"), - QObject::tr("Whether System One resistance settings are available to you."), - QObject::tr("Sys1 Resist. Lock"), + channel.add(GRP_CPAP, chan = new Channel(PRS1_MaskResistLock = 0xe108, SETTING, MT_CPAP, SESSION, + "MaskResistLock", + QObject::tr("Mask Resistance Lock"), + QObject::tr("Whether mask resistance settings are available to you."), + QObject::tr("Mask Resist. Lock"), "", LOOKUP, Qt::black)); chan->addOption(0, STR_TR_Off); chan->addOption(1, STR_TR_On); diff --git a/oscar/SleepLib/machine_common.cpp b/oscar/SleepLib/machine_common.cpp index b11e6dd5..dc677d74 100644 --- a/oscar/SleepLib/machine_common.cpp +++ b/oscar/SleepLib/machine_common.cpp @@ -31,9 +31,8 @@ ChannelID RMS9_E01, RMS9_E02, RMS9_SetPressure, RMS9_MaskOnTime; ChannelID INTELLIPAP_Unknown1, INTELLIPAP_Unknown2; ChannelID PRS1_0E, CPAP_LargeLeak, - PRS1_BND, PRS1_FlexMode, PRS1_FlexLevel, PRS1_HumidStatus, PRS1_HumidLevel, PRS1_SysLock, - PRS1_SysOneResistStat, - PRS1_SysOneResistSet, PRS1_HoseDiam, PRS1_AutoOn, PRS1_AutoOff, PRS1_MaskAlert, PRS1_ShowAHI; + PRS1_BND, PRS1_FlexMode, PRS1_FlexLevel, PRS1_HumidStatus, PRS1_HumidLevel, PRS1_MaskResistLock, + PRS1_MaskResistSet, PRS1_HoseDiam, PRS1_AutoOn, PRS1_AutoOff, PRS1_MaskAlert, PRS1_ShowAHI; ChannelID OXI_Pulse, OXI_SPO2, OXI_Perf, OXI_PulseChange, OXI_SPO2Drop, OXI_Plethy; diff --git a/oscar/SleepLib/machine_common.h b/oscar/SleepLib/machine_common.h index b532a425..7bd77371 100644 --- a/oscar/SleepLib/machine_common.h +++ b/oscar/SleepLib/machine_common.h @@ -158,9 +158,8 @@ extern ChannelID CPAP_IPAP, CPAP_IPAPLo, CPAP_IPAPHi, CPAP_EPAP, CPAP_EPAPLo, CP extern ChannelID RMS9_E01, RMS9_E02, RMS9_SetPressure, RMS9_MaskOnTime; extern ChannelID PRS1_0E, CPAP_LargeLeak, PRS1_BND, - PRS1_FlexMode, PRS1_FlexLevel, PRS1_HumidStatus, PRS1_HumidLevel, CPAP_HumidSetting, PRS1_SysLock, - PRS1_SysOneResistStat, - PRS1_SysOneResistSet, PRS1_HoseDiam, PRS1_AutoOn, PRS1_AutoOff, PRS1_MaskAlert, PRS1_ShowAHI; + PRS1_FlexMode, PRS1_FlexLevel, PRS1_HumidStatus, PRS1_HumidLevel, CPAP_HumidSetting, PRS1_MaskResistLock, + PRS1_MaskResistSet, PRS1_HoseDiam, PRS1_AutoOn, PRS1_AutoOff, PRS1_MaskAlert, PRS1_ShowAHI; extern ChannelID INTELLIPAP_Unknown1, INTELLIPAP_Unknown2; diff --git a/oscar/tests/sessiontests.cpp b/oscar/tests/sessiontests.cpp index 408f124a..f05bd9d7 100644 --- a/oscar/tests/sessiontests.cpp +++ b/oscar/tests/sessiontests.cpp @@ -87,8 +87,8 @@ static QString settingChannel(ChannelID i) CHANNELNAME(PRS1_HumidMode); CHANNELNAME(PRS1_TubeTemp); CHANNELNAME(PRS1_HumidLevel); - CHANNELNAME(PRS1_SysLock); - CHANNELNAME(PRS1_SysOneResistSet); + CHANNELNAME(PRS1_MaskResistLock); + CHANNELNAME(PRS1_MaskResistSet); CHANNELNAME(PRS1_TimedBreath); CHANNELNAME(PRS1_HoseDiam); CHANNELNAME(PRS1_AutoOn);