Index: denali.pro.user =================================================================== diff -u -r426208cdb707400759bdc663b871ece9d1208aed -r94f7349bd073a732dba5295250fc0e26f740743c --- denali.pro.user (.../denali.pro.user) (revision 426208cdb707400759bdc663b871ece9d1208aed) +++ denali.pro.user (.../denali.pro.user) (revision 94f7349bd073a732dba5295250fc0e26f740743c) @@ -1,6 +1,6 @@ - + EnvironmentId @@ -68,7 +68,7 @@ Qt 5.12.5 (iMX8) Qt 5.12.5 (iMX8) {5d6458ef-f917-4aef-a092-c77bbe106149} - 0 + 1 0 0 @@ -373,7 +373,7 @@ Desktop Qt 5.12.5 GCC 64bit Desktop Qt 5.12.5 GCC 64bit qt.qt5.5125.gcc_64_kit - 1 + 0 0 0 @@ -999,7 +999,7 @@ true false - /home/denali/Project/tmp/build/denali-Desktop_Qt_5_12_5_GCC_64bit-Release + 1 Index: denali.qrc =================================================================== diff -u -r426208cdb707400759bdc663b871ece9d1208aed -r94f7349bd073a732dba5295250fc0e26f740743c --- denali.qrc (.../denali.qrc) (revision 426208cdb707400759bdc663b871ece9d1208aed) +++ denali.qrc (.../denali.qrc) (revision 94f7349bd073a732dba5295250fc0e26f740743c) @@ -38,6 +38,9 @@ sources/gui/qml/components/ProgressRect.qml sources/gui/qml/components/RangeRect.qml sources/gui/qml/components/RangeBar.qml + sources/gui/qml/components/Circle.qml + sources/gui/qml/components/TimeText.qml + sources/gui/qml/components/ProgressCircle.qml qtquickcontrols2.conf Index: sources/canbus/caninterface.cpp =================================================================== diff -u -r805119c460b4a266d6401c8705f4427e7fbe270f -r94f7349bd073a732dba5295250fc0e26f740743c --- sources/canbus/caninterface.cpp (.../caninterface.cpp) (revision 805119c460b4a266d6401c8705f4427e7fbe270f) +++ sources/canbus/caninterface.cpp (.../caninterface.cpp) (revision 94f7349bd073a732dba5295250fc0e26f740743c) @@ -113,7 +113,7 @@ this , SLOT (onFrameError (QCanBusDevice::CanBusError))); connect(_canDevice, SIGNAL( framesWritten(qint64)), - this , SLOT (onFrameWrittern(qint64))); + this , SLOT (onFrameWritten (qint64))); } connect(&_FrameInterface, SIGNAL(didFrameTransmit(QCanBusFrame)), this , SLOT( onFrameTransmit(QCanBusFrame))); @@ -336,17 +336,17 @@ } /*! - * \brief CanInterface::onFrameWrittern + * \brief CanInterface::onFrameWritten * \details This is the slot connected to the signal * which is emitted every time a payload of frames * has been written to the CANBUS bus. * \param vFramesCount - The framesCount argument is set to the number of frames * that were written in this payload. */ -void CanInterface::onFrameWrittern(qint64 /*vFramesCount*/) +void CanInterface::onFrameWritten(qint64 /*vFramesCount*/) { //_txFrameCount = vFramesCount; - //qDebug() << "onFrameWrittern::FramesCount : " << vFramesCount; + //qDebug() << "onFrameWritten::FramesCount : " << vFramesCount; } /*! Index: sources/canbus/caninterface.h =================================================================== diff -u -r805119c460b4a266d6401c8705f4427e7fbe270f -r94f7349bd073a732dba5295250fc0e26f740743c --- sources/canbus/caninterface.h (.../caninterface.h) (revision 805119c460b4a266d6401c8705f4427e7fbe270f) +++ sources/canbus/caninterface.h (.../caninterface.h) (revision 94f7349bd073a732dba5295250fc0e26f740743c) @@ -120,12 +120,12 @@ */ void didFrameTransmit(bool ok); -public slots: +public slots: private slots: void onFrameTransmit (const QCanBusFrame &vFrame); void onFrameReceive (); void onFrameError (QCanBusDevice::CanBusError vError); - void onFrameWrittern (qint64 vFramesCount); + void onFrameWritten (qint64 vFramesCount); }; } Index: sources/gui/qml/components/Circle.qml =================================================================== diff -u --- sources/gui/qml/components/Circle.qml (revision 0) +++ sources/gui/qml/components/Circle.qml (revision 94f7349bd073a732dba5295250fc0e26f740743c) @@ -0,0 +1,78 @@ +/*! + * + * Copyright (c) 2019-2020 Diality Inc. - All Rights Reserved. + * \copyright \n + * THIS CODE MAY NOT BE COPIED OR REPRODUCED IN ANY FORM, \n + * IN PART OR IN WHOLE, \n + * WITHOUT THE EXPLICIT PERMISSION OF THE COPYRIGHT OWNER. \n + * + * \file Circle.qml + * \date 2020/02/03 + * \author Behrouz NematiPour + * + */ + +// Qt +import QtQuick 2.12 +import QtQuick.Controls 2.12 +import QtQuick.Shapes 1.12 + +// Project + +// Qml imports +import "qrc:/globals" +import "qrc:/components" + +/*! + * \brief Drawing Circle Component + */ +Item { id: _root + property alias thickness : _path.strokeWidth + property alias color : _path.strokeColor + property alias shadow : _rectangle.border + property int shadowEdge : 1 + property alias fillColor : _rectangle.color + property alias capStyle : _path.capStyle + + property alias angle : _arc.sweepAngle + property alias startAngle : _arc.startAngle + + property real diameter : 350 + + width : diameter + height : diameter + + Rectangle { id: _rectangle + anchors.centerIn: _root + width : _root.width + height : _root.height + radius : _root.width + color : "Transparent" + border.width: _root.thickness + shadowEdge * 2 + border.color: "Transparent" + antialiasing: true + Shape { id: _shape + width: parent.width + height: parent.height + layer.enabled: true + layer.smooth: true + layer.textureSize: Qt.size(_shape.width * 2, _shape.height * 2) + ShapePath { id: _path + fillColor: "Transparent" + strokeColor: Colors.borderButton + strokeWidth: 2 + capStyle: ShapePath.RoundCap + PathAngleArc { id: _arc + centerX: _root.width / 2 + centerY: _root.height / 2 + radiusX: (diameter - _path.strokeWidth - (shadowEdge * 2) ) / 2 + radiusY: (diameter - _path.strokeWidth - (shadowEdge * 2) ) / 2 + startAngle: -90 + sweepAngle: 0 + } + } + } + } +} + + Index: sources/gui/qml/components/ModalDialog.qml =================================================================== diff -u -rc933552983a659ca4cc351ff4d43d07319adab1e -r94f7349bd073a732dba5295250fc0e26f740743c --- sources/gui/qml/components/ModalDialog.qml (.../ModalDialog.qml) (revision c933552983a659ca4cc351ff4d43d07319adab1e) +++ sources/gui/qml/components/ModalDialog.qml (.../ModalDialog.qml) (revision 94f7349bd073a732dba5295250fc0e26f740743c) @@ -25,11 +25,9 @@ * \brief The parent item for modal dialogs */ Dialog { id : _root - property bool blurOverlay: false - - width : Variables.poweroffWidth - height: Variables.poweroffHeight - visible: false + width : Variables.poweroffWidth + height : Variables.poweroffHeight + visible : false anchors.centerIn: parent enter: Transition { NumberAnimation { property: "opacity"; from: 0.0; to: 1.0 } } @@ -42,16 +40,9 @@ color: Colors.borderDialog } } - Component { id: _blurOverlay - FastBlur { id : _borderRect - anchors.fill: parent - source: _mainItem - radius: 25 - } - } closePolicy: Dialog.NoAutoClose - Overlay.modal : blurOverlay ? _blurOverlay : _rectOverlay + Overlay.modal : _rectOverlay background: Rectangle { id: _backgroundRect color : Colors.backgroundDialog Index: sources/gui/qml/components/ProgressCircle.qml =================================================================== diff -u --- sources/gui/qml/components/ProgressCircle.qml (revision 0) +++ sources/gui/qml/components/ProgressCircle.qml (revision 94f7349bd073a732dba5295250fc0e26f740743c) @@ -0,0 +1,43 @@ +/*! + * + * Copyright (c) 2019-2020 Diality Inc. - All Rights Reserved. + * \copyright \n + * THIS CODE MAY NOT BE COPIED OR REPRODUCED IN ANY FORM, \n + * IN PART OR IN WHOLE, \n + * WITHOUT THE EXPLICIT PERMISSION OF THE COPYRIGHT OWNER. \n + * + * \file ProgressCircle.qml + * \date 2020/02/03 + * \author Behrouz NematiPour + * + */ + +// Qt +import QtQuick 2.12 +import QtQuick.Controls 2.12 + +// Project +// Qml imports +import "qrc:/globals" + +/*! + * \brief Denali project Progress Circle + */ +Item { id: _root + property int minimum : 0 + property int maximum : 0 + property int value : minimum + + width : parent.width + height : parent.height + + QtObject { id: _private + property int value: ((360 * (_root.value - _root.minimum)) / (_root.maximum - _root.minimum)) + } + + Circle { id: _circle + anchors.centerIn: parent + shadow.color : Colors.backgroundMainMenu + angle : _private.value + } +} Index: sources/gui/qml/components/TimeText.qml =================================================================== diff -u --- sources/gui/qml/components/TimeText.qml (revision 0) +++ sources/gui/qml/components/TimeText.qml (revision 94f7349bd073a732dba5295250fc0e26f740743c) @@ -0,0 +1,83 @@ +/*! + * + * Copyright (c) 2019-2020 Diality Inc. - All Rights Reserved. + * \copyright \n + * THIS CODE MAY NOT BE COPIED OR REPRODUCED IN ANY FORM, \n + * IN PART OR IN WHOLE, \n + * WITHOUT THE EXPLICIT PERMISSION OF THE COPYRIGHT OWNER. \n + * + * \file TimeText.qml + * \date 2020/02/03 + * \author Behrouz NematiPour + * + */ + +// Qt +import QtQuick 2.12 +import QtQuick.Controls 2.12 + +// Project + +// Qml imports +import "qrc:/globals" + +/*! + * \brief Time Text Component converts seconds into hour:minute.second + */ +Item { id: _root + property int seconds : 0 + property color color : "white" + property int textPixelSize : 90 + property int secsPixelSize : 16 + + width : _timeHour.contentWidth + _timeSeparator.contentWidth + _timeMinute.contentWidth + height: _timeSeparator.height + + QtObject { id: _private + property int hour : Math.floor( seconds / 3600 ) + property int minute : Math.floor((seconds % 3600) / 60); + property int second : seconds % 60 + } + + Text { id: _timeSeparator + text: ":" + + font.pixelSize: _root.textPixelSize + font.weight: Font.ExtraLight + color: _root.color + + anchors.centerIn: _root + } + Text { id: _timeHour + property alias hour: _private.hour + font.pixelSize: _root.textPixelSize + font.weight: Font.ExtraLight + color: _root.color + + horizontalAlignment: Text.AlignRight + anchors.right : _timeSeparator.left + anchors.baseline: _timeSeparator.baseline + + text: (hour < 10 ? "0"+hour : hour) + } + Text { id: _timeMinute + property alias minute: _private.minute + text: (minute < 10 ? "0" + minute : minute) + font.pixelSize: _root.textPixelSize + font.weight: Font.ExtraLight + color: _root.color + horizontalAlignment: Text.AlignLeft + anchors.left: _timeSeparator.right + anchors.baseline: _timeSeparator.baseline + } + Text { id: _timeSecond + property alias second: _private.second + text: (second < 10 ? "0" + second : second) + font.pixelSize: _root.secsPixelSize + color: _root.color + horizontalAlignment: Text.AlignLeft + anchors.left: _timeMinute.right + anchors.baseline: _timeSeparator.baseline + } +} + Index: sources/gui/qml/components/TouchRect.qml =================================================================== diff -u -r227f28b202f81ab3dd04a81868697025ccab6220 -r94f7349bd073a732dba5295250fc0e26f740743c --- sources/gui/qml/components/TouchRect.qml (.../TouchRect.qml) (revision 227f28b202f81ab3dd04a81868697025ccab6220) +++ sources/gui/qml/components/TouchRect.qml (.../TouchRect.qml) (revision 94f7349bd073a732dba5295250fc0e26f740743c) @@ -36,7 +36,7 @@ property color textColor : Colors.textButton property color borderColor : Colors.borderButton - property color backgroungColor : Colors.backgroundButtonNormal + property color backgroundColor : Colors.backgroundButtonNormal onDurationChanged: { _colorAnimationOn .duration = duration; @@ -51,12 +51,12 @@ } } else { _clickAnimation.stop() - _root.color = backgroungColor + _root.color = backgroundColor } } - onBackgroungColorChanged: { - _root.color = backgroungColor + onBackgroundColorChanged: { + _root.color = backgroundColor } onDisabledChanged: { @@ -72,7 +72,7 @@ width : Variables.touchRectWidth height : Variables.touchRectHeight radius : Variables.touchRectRadius - color : backgroungColor + color : backgroundColor border { color: Colors.borderButton width: Variables.borderWidth @@ -93,10 +93,10 @@ SequentialAnimation { id: _clickAnimation running: false onStopped: { - _root.color = backgroungColor + _root.color = backgroundColor } onFinished: { - _root.color = backgroungColor + _root.color = backgroundColor } PropertyAnimation { id: _colorAnimationOn ; target: _root; property: "color"; to: _root.border.color; duration: duration; } PropertyAnimation { id: _colorAnimationOff; target: _root; property: "color"; to: _root.color ; duration: duration; } Index: sources/gui/qml/dialogs/PowerOff.qml =================================================================== diff -u -r62efc6d8ead9b39b47859fdc9c0661f30b5941d0 -r94f7349bd073a732dba5295250fc0e26f740743c --- sources/gui/qml/dialogs/PowerOff.qml (.../PowerOff.qml) (revision 62efc6d8ead9b39b47859fdc9c0661f30b5941d0) +++ sources/gui/qml/dialogs/PowerOff.qml (.../PowerOff.qml) (revision 94f7349bd073a732dba5295250fc0e26f740743c) @@ -25,7 +25,6 @@ * \brief Contains the PowerOff Dialog Implementation */ ModalDialog { id : _root - blurOverlay: false Column { spacing: Variables.columnSpacing anchors.centerIn: parent Index: sources/gui/qml/pages/treatment/TreatmentStart.qml =================================================================== diff -u -r326606dbdcecb69059550bdc4dadeeac78830101 -r94f7349bd073a732dba5295250fc0e26f740743c --- sources/gui/qml/pages/treatment/TreatmentStart.qml (.../TreatmentStart.qml) (revision 326606dbdcecb69059550bdc4dadeeac78830101) +++ sources/gui/qml/pages/treatment/TreatmentStart.qml (.../TreatmentStart.qml) (revision 94f7349bd073a732dba5295250fc0e26f740743c) @@ -85,8 +85,9 @@ _ultrafiltrationTouchArea.value = vData[GuiActions.DialysateOutletFlow_MeasUFVol].toFixed(2); break; case GuiActions.TreatmentTime: - _treatmentTime.maximum = vData[GuiActions.TreatmentTime_Total ]; - _treatmentTime.value = vData[GuiActions.TreatmentTime_Elapsed]; + _treatmentTime.maximum = vData[GuiActions.TreatmentTime_Total ]; + _treatmentTime.progressValue = vData[GuiActions.TreatmentTime_Elapsed ]; + _treatmentTime.timeTextValue = vData[GuiActions.TreatmentTime_Remaining ]; break; } } Index: sources/gui/qml/pages/treatment/sections/TreatmentTime.qml =================================================================== diff -u -r326606dbdcecb69059550bdc4dadeeac78830101 -r94f7349bd073a732dba5295250fc0e26f740743c --- sources/gui/qml/pages/treatment/sections/TreatmentTime.qml (.../TreatmentTime.qml) (revision 326606dbdcecb69059550bdc4dadeeac78830101) +++ sources/gui/qml/pages/treatment/sections/TreatmentTime.qml (.../TreatmentTime.qml) (revision 94f7349bd073a732dba5295250fc0e26f740743c) @@ -28,94 +28,35 @@ * \brief Treatment Screen Treatment Time Remaining section */ Rectangle { id: _treatmentTime - property int minimum : 0 - property int maximum : 0 - property int value : minimum + property int minimum : 0 + property int maximum : 0 + property int progressValue : minimum + property int timeTextValue : minimum signal clicked() - QtObject { id: _private - property int length: ((360 * (_treatmentTime.value - _treatmentTime.minimum)) / (_treatmentTime.maximum - _treatmentTime.minimum)) - property int seconds: _treatmentTime.value; - property int hour : Math.floor( seconds / 3600 ) - property int minute : Math.floor((seconds % 3600) / 60); - property int second : seconds % 60 - } - anchors.centerIn: parent - width: 336 - height: 336 - radius: width - color: "Transparent" - border.width: 4 - border.color: Colors.backgroundMainMenu - Shape { id: _shape - width: parent.width - height: parent.height - layer.enabled: true - layer.smooth: true - layer.textureSize: Qt.size(_shape.width * 2, _shape.height * 2) - ShapePath { - fillColor: "Transparent" - strokeColor: Colors.borderButton - strokeWidth: 2 - PathAngleArc { - centerX: _treatmentTime.width / 2 - centerY: _treatmentTime.height / 2 - radiusX: 166 - radiusY: 166 - startAngle: -90 - sweepAngle: _private.length - } - } - } - Text { id: _timeSeparator - text: ":" + width : _circle.width + height: _circle.height + color: "transparent" - font.pixelSize: 90 - font.weight: Font.ExtraLight - color: "white" + ProgressCircle { id: _circle + minimum: _treatmentTime.minimum + maximum: _treatmentTime.maximum - anchors.centerIn: parent - anchors.topMargin: 50 - + anchors.centerIn : parent + value: _treatmentTime.progressValue } - Text { id: _timeHour - property alias hour: _private.hour - font.pixelSize: 90 - font.weight: Font.ExtraLight - color: "white" - horizontalAlignment: Text.AlignRight - anchors.right: _timeSeparator.left - anchors.baseline: _timeSeparator.baseline - - text: (hour < 10 ? "0"+hour : hour) + TimeText { id: _timeText + anchors.centerIn : parent + seconds : _treatmentTime.timeTextValue } - Text { id: _timeMinute - property alias minute: _private.minute - text: (minute < 10 ? "0" + minute : minute) - font.pixelSize: 90 - font.weight: Font.ExtraLight - color: "white" - horizontalAlignment: Text.AlignLeft - anchors.left: _timeSeparator.right - anchors.baseline: _timeSeparator.baseline - } - Text { id: _timeSecond - property alias second: _private.second - text: (second < 10 ? "0" + second : second) - font.pixelSize: 16 - //font.weight: Font.ExtraLight - color: "white" - horizontalAlignment: Text.AlignLeft - anchors.left: _timeMinute.right - anchors.baseline: _timeSeparator.baseline - } + Rectangle { id: _timeTitleRect color: "Transparent" - anchors.horizontalCenter: _timeSeparator.horizontalCenter - anchors.bottom: _timeSeparator.top + anchors.horizontalCenter: _timeText.horizontalCenter + anchors.bottom: _timeText.top width : _timeTitle.width + _arrowImage.width + _arrowImage.anchors.leftMargin height : _timeTitle.height Index: sources/storage/logger.h =================================================================== diff -u -r426208cdb707400759bdc663b871ece9d1208aed -r94f7349bd073a732dba5295250fc0e26f740743c --- sources/storage/logger.h (.../logger.h) (revision 426208cdb707400759bdc663b871ece9d1208aed) +++ sources/storage/logger.h (.../logger.h) (revision 94f7349bd073a732dba5295250fc0e26f740743c) @@ -89,6 +89,8 @@ eLogEvent, eLogError, eLogDatum, + + eLogType_Count, }; private: