Index: sources/gui/qml/pages/treatment/sections/TreatmentTime.qml =================================================================== diff -u -r44a85c96ab55e424866ec4cca0270aa218355f82 -r0e528e5f706308c7b0e8f22a4d9dbb5b5715db7c --- sources/gui/qml/pages/treatment/sections/TreatmentTime.qml (.../TreatmentTime.qml) (revision 44a85c96ab55e424866ec4cca0270aa218355f82) +++ sources/gui/qml/pages/treatment/sections/TreatmentTime.qml (.../TreatmentTime.qml) (revision 0e528e5f706308c7b0e8f22a4d9dbb5b5715db7c) @@ -1,16 +1,16 @@ /*! - * + * * Copyright (c) 2019-2020 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 TreatmentTime.qml * \author (last) Behrouz NematiPour * \date (last) 27-Apr-2020 * \author (original) Behrouz NematiPour * \date (original) 31-Jan-2020 - * + * */ // Qt @@ -32,6 +32,9 @@ property int progressValue : vTreatmentTime.time_Elapsed property int timeTextValue : vTreatmentTime.time_Remaining + property bool isPaused : vHDTreatmentStates.txPaused + + signal clicked() anchors.centerIn: parent @@ -50,6 +53,7 @@ TimeText { id: _timeText anchors.centerIn : parent seconds : _root.timeTextValue + secondsVisible: ! _root.isPaused } Rectangle { id: _timeTitleRect @@ -68,7 +72,7 @@ anchors.left: parent.left Image { id: _arrowImage - visible: true + visible: ! _root.isPaused anchors.left : parent.right anchors.bottom: parent.baseline anchors.leftMargin: 10 @@ -79,10 +83,30 @@ } } + NotificationBarSmall { id: _notification + visible : _root.isPaused + height : 25 + imageAutoSize: false + imageAnimated: true + color: "transparent" + anchors { + leftMargin : 80 + bottomMargin: 80 + } + + imageSource : "qrc:/images/iPauseGray" + text : qsTr("Treatment Paused") + textColor : "gray" + textfontSize: 16 + rowAnchors.centerIn: null + } + MouseArea { id: _mouseArea anchors.fill: parent onClicked: { - _root.clicked() + if (! _root.isPaused) { + _root.clicked() + } } } }