Index: sources/gui/qml/pages/treatment/sections/TreatmentSaline.qml =================================================================== diff -u -ra2e7e903bf3fdc242ba77d99f3daa9c4208cc1f1 -r2ef03b2ce51b4dc507f66e9671953a8e0824bde9 --- sources/gui/qml/pages/treatment/sections/TreatmentSaline.qml (.../TreatmentSaline.qml) (revision a2e7e903bf3fdc242ba77d99f3daa9c4208cc1f1) +++ sources/gui/qml/pages/treatment/sections/TreatmentSaline.qml (.../TreatmentSaline.qml) (revision 2ef03b2ce51b4dc507f66e9671953a8e0824bde9) @@ -1,15 +1,15 @@ /*! * - * Copyright (c) 2019-2020 Diality Inc. - All Rights Reserved. + * Copyright (c) 2020-2024 Diality Inc. - All Rights Reserved. * \copyright * THIS CODE MAY NOT BE COPIED OR REPRODUCED IN ANY FORM, IN PART OR IN * WHOLE, WITHOUT THE EXPLICIT PERMISSION OF THE COPYRIGHT OWNER. * - * \file TreatmentSaline.qml - * \author (last) Behrouz NematiPour - * \date (last) 16-Oct-2020 - * \author (original) Behrouz NematiPour - * \date (original) 10-Aug-2020 + * \file TreatmentSaline.qml + * \author (last) Vy + * \date (last) 18-May-2023 + * \author (original) Behrouz NematiPour + * \date (original) 10-Aug-2020 * */ @@ -43,30 +43,34 @@ readonly property string mesgRejectReason : vTreatmentAdjustmentSaline.adjustment_ReasonText } - hasArrow : false - isTouchable : ! ( _root.isDisabled || _root.isWaitPump ) - buttonText : _root.isDisabled ? (_private.textStart || _root.isWaitPump ): - _root.isStarted ? _private.textStop : - _private.textStart + hasArrow : false + isTouchable : false + buttonEnabled : ! ( _root.isDisabled || _root.isWaitPump ) + buttonText : ( _root.isDisabled || _root.isWaitPump ) ? _private.textStart : + _root.isStarted ? _private.textStop : + _private.textStart + + fluidProgressBarColor: _root.isStarted ? Colors.sliderHighlightColor : Colors.highlightProgressBar + title : qsTr("SALINE BOLUS") unit : Variables.unitTextSaline - valueTarget : vTreatmentSaline.target || vTreatmentAdjustmentSaline.target - valueCumulative: vTreatmentSaline.cumulative .toFixed(0) - valueDelivered : vTreatmentSaline.delivered .toFixed(0) + valueDecimal : Variables.salinePrecision + valueTarget : vTreatmentSaline.target || vTreatmentAdjustmentSaline.target + valueCumulative : vTreatmentSaline.cumulative + valueDelivered : vTreatmentSaline.delivered VTreatmentSaline { id: vTreatmentSaline } onClicked: { - vTreatmentAdjustmentSaline.doAdjustment() + if ( isIdle ) vTreatmentAdjustmentSaline.doStart() // IDLE + if ( isStarted ) vTreatmentAdjustmentSaline.doStop () // IN_PROGRESS } notification { visible : true - text : isIdle ? "" : - isDisabled ? _private.mesgDisabled : - isWaitPump ? _private.mesgWaitForPump : - isStarted ? _private.mesgRejectReason : - "" + text : isDisabled ? _private.mesgDisabled : + isWaitPump ? _private.mesgWaitForPump : + _private.mesgRejectReason } }