Index: sources/view/hd/data/VHDTreatmentStatesData.cpp =================================================================== diff -u -r28a383251ad37c669202c0a717ff90b8fc21a442 -r07e0c7bd409782cab96a4ae761ee3f819bdb8639 --- sources/view/hd/data/VHDTreatmentStatesData.cpp (.../VHDTreatmentStatesData.cpp) (revision 28a383251ad37c669202c0a717ff90b8fc21a442) +++ sources/view/hd/data/VHDTreatmentStatesData.cpp (.../VHDTreatmentStatesData.cpp) (revision 07e0c7bd409782cab96a4ae761ee3f819bdb8639) @@ -75,13 +75,9 @@ // Treatment states // Treatment states - Basics txStart ( vData.mSubMode == GuiTreatmentStates ::TREATMENT_START_STATE ); - txBloodPrime ( vData.mSubMode == GuiTreatmentStates ::TREATMENT_BLOOD_PRIME_STATE ); - txStop ( vData.mSubMode == GuiTreatmentStates ::TREATMENT_STOP_STATE ); - txEnd ( vData.mSubMode == GuiTreatmentStates ::TREATMENT_END_STATE ); // Treatment states - Dialysis - txDialysisRunning ( vData.mSubMode == GuiTreatmentStates ::TREATMENT_DIALYSIS_STATE ); - txDialysisEnd ( vData.mSubMode == GuiTreatmentStates ::TREATMENT_DIALYSIS_END_STATE ); + txDialysis ( vData.mSubMode == GuiTreatmentStates ::TREATMENT_DIALYSIS_STATE ); // NOTE: For Rinseback and Recirculate // 1 - it seems we may never need the txRinseback @@ -96,23 +92,46 @@ // Treatment states - Rinse back // Rinseback states - bool mRinseback = vData.mSubMode == GuiTreatmentStates ::TREATMENT_RINSEBACK_STATE ; + bool mRinseback = vData.mSubMode == GuiTreatmentStates ::TREATMENT_RINSEBACK_STATE ; if ( mRinseback ) { - rbInit ( vData.mRinsebackState == GuiRinsebackStates ::RINSEBACK_STOP_INIT_STATE ); - rbRun ( vData.mRinsebackState == GuiRinsebackStates ::RINSEBACK_RUN_STATE ); - rbPaused ( vData.mRinsebackState == GuiRinsebackStates ::RINSEBACK_PAUSED_STATE ); - rbStop ( vData.mRinsebackState == GuiRinsebackStates ::RINSEBACK_STOP_STATE ); - rbAdditional ( vData.mRinsebackState == GuiRinsebackStates ::RINSEBACK_RUN_ADDITIONAL_STATE ); + rbInit ( vData.mRinsebackState == GuiRinsebackStates ::RINSEBACK_STOP_INIT_STATE ); + rbRun ( vData.mRinsebackState == GuiRinsebackStates ::RINSEBACK_RUN_STATE ); + rbPaused ( vData.mRinsebackState == GuiRinsebackStates ::RINSEBACK_PAUSED_STATE ); + rbStop ( vData.mRinsebackState == GuiRinsebackStates ::RINSEBACK_STOP_STATE ); + rbAdditional ( vData.mRinsebackState == GuiRinsebackStates ::RINSEBACK_RUN_ADDITIONAL_STATE ); } txRinseback ( mRinseback ); // it's the main rinseback even so moved last to have all the sub-rinseback-states updated prior to. // Recirculate states - bool mRecirculate = vData.mSubMode == GuiTreatmentStates ::TREATMENT_RECIRC_STATE ; + bool mRecirculate = vData.mSubMode == GuiTreatmentStates ::TREATMENT_RECIRC_STATE ; if ( mRecirculate ) { - rcStarted ( vData.mRecirculateState == GuiRecirculateStates ::TREATMENT_RECIRC_RECIRC_STATE ); - rcStopped ( vData.mRecirculateState == GuiRecirculateStates ::TREATMENT_RECIRC_STOPPED_STATE ); + rcStarted ( vData.mRecirculateState == GuiRecirculateStates ::TREATMENT_RECIRC_RECIRC_STATE ); + rcStopped ( vData.mRecirculateState == GuiRecirculateStates ::TREATMENT_RECIRC_STOPPED_STATE ); } txRecirculate ( mRecirculate ); // it's the main recirculate even so moved last to have all the sub-recirculate-states updated prior to. + + // Blood Prime states + bool mBloodPrime = vData.mSubMode == GuiTreatmentStates ::TREATMENT_BLOOD_PRIME_STATE ; + if ( mBloodPrime ) { + bpRamp ( vData.mBloodPrimeState == GuiBloodPrimeStates ::BLOOD_PRIME_RAMP_STATE ); + } + txBloodPrime ( mBloodPrime ); + + // Treatment End states + bool mTreatmentEnd = vData.mSubMode == GuiTreatmentStates ::TREATMENT_END_STATE ; + if ( mTreatmentEnd ) { + teWaitRinseback ( vData.mTreatmentEndState == GuiTreatmentEndStates ::TREATMENT_END_WAIT_FOR_RINSEBACK_STATE ); + tePaused ( vData.mTreatmentEndState == GuiTreatmentEndStates ::TREATMENT_END_PAUSED_STATE ); + } + txEnd ( mTreatmentEnd ); + + // Treatment Stop states + bool mTreatmentStop = vData.mSubMode == GuiTreatmentStates ::TREATMENT_STOP_STATE ; + if ( mTreatmentStop ) { + tsRecirculate ( vData.mTreatmentStopState == GuiTreatmentStopStates ::TREATMENT_STOP_RECIRC_STATE ); + tsRecirculateNo ( vData.mTreatmentStopState == GuiTreatmentStopStates ::TREATMENT_STOP_NO_RECIRC_STATE ); + } + txStop ( mTreatmentStop ); } /*!