Index: sources/view/hd/data/VHDTreatmentStatesData.cpp =================================================================== diff -u -r2d37388a2b6651ea4002d6720e933315e0ba7fa3 -r28a383251ad37c669202c0a717ff90b8fc21a442 --- sources/view/hd/data/VHDTreatmentStatesData.cpp (.../VHDTreatmentStatesData.cpp) (revision 2d37388a2b6651ea4002d6720e933315e0ba7fa3) +++ sources/view/hd/data/VHDTreatmentStatesData.cpp (.../VHDTreatmentStatesData.cpp) (revision 28a383251ad37c669202c0a717ff90b8fc21a442) @@ -86,7 +86,7 @@ // NOTE: For Rinseback and Recirculate // 1 - it seems we may never need the txRinseback // since in the Rinseback state parameter of the Treatment State the first state of each has the same meaning - // it may only be used to know when those parameter has valid values to update the properties. + // it may only be used to know when those parameters have valid values to update the properties. // Kept for now because cannot be sure that it will change later or not. // 2 - if there could be a way to export enums to qml and qml can raise an error if an incorrect enum used, // then it would is absolutely preferred to use enum instead of properties @@ -95,23 +95,24 @@ // in Qt user/developer can literally type GuiActions.abcdefg and qml will never complain and only if compared with the state will return false. // Treatment states - Rinse back - txRinseback ( vData.mSubMode == GuiTreatmentStates ::TREATMENT_RINSEBACK_STATE ); // Rinseback states - if ( _txRinseback ) { - rbSInit ( vData.mRinsebackState == GuiRinsebackStates ::RINSEBACK_STOP_INIT_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 ); } - // NOTE: refer to the note above - // Treatment states - Recirculate - txRecirculate ( vData.mSubMode == GuiTreatmentStates ::TREATMENT_RECIRC_STATE ); + txRinseback ( mRinseback ); // it's the main rinseback even so moved last to have all the sub-rinseback-states updated prior to. + // Recirculate states - if ( _txRecirculate ) { + 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 ); } + txRecirculate ( mRecirculate ); // it's the main recirculate even so moved last to have all the sub-recirculate-states updated prior to. } /*!