Index: denali.pro.user =================================================================== diff -u -r7a1509a80fed2dd51aa28b460acbf0227d0c96d7 -r3229695c1c67de600c095d52c6f99dacfafb462d --- denali.pro.user (.../denali.pro.user) (revision 7a1509a80fed2dd51aa28b460acbf0227d0c96d7) +++ denali.pro.user (.../denali.pro.user) (revision 3229695c1c67de600c095d52c6f99dacfafb462d) @@ -1,6 +1,6 @@ - + EnvironmentId Index: denali.qrc =================================================================== diff -u -r97d593e2e7adb36f2f9f97f9bb9958dcef740bc1 -r3229695c1c67de600c095d52c6f99dacfafb462d --- denali.qrc (.../denali.qrc) (revision 97d593e2e7adb36f2f9f97f9bb9958dcef740bc1) +++ denali.qrc (.../denali.qrc) (revision 3229695c1c67de600c095d52c6f99dacfafb462d) @@ -117,6 +117,7 @@ sources/gui/qml/components/FooterStatic.qml sources/gui/qml/components/TimeEntry.qml sources/gui/qml/components/Label.qml + sources/gui/qml/components/EntryDialog.qml sources/gui/qml/compounds/PressureRangeSlider.qml Index: sources/gui/qml/components/CloseButton.qml =================================================================== diff -u -r1a8e9578b27bb3877116675d0b2361ce4f5b5539 -r3229695c1c67de600c095d52c6f99dacfafb462d --- sources/gui/qml/components/CloseButton.qml (.../CloseButton.qml) (revision 1a8e9578b27bb3877116675d0b2361ce4f5b5539) +++ sources/gui/qml/components/CloseButton.qml (.../CloseButton.qml) (revision 3229695c1c67de600c095d52c6f99dacfafb462d) @@ -29,7 +29,7 @@ anchors { top : parent.top - right : parent.right + left : parent.left margins : 35 } Image { id : _image Index: sources/gui/qml/components/ConfirmButton.qml =================================================================== diff -u -rc0c63c4b149dafea2b02e4cd31f223e392ff7818 -r3229695c1c67de600c095d52c6f99dacfafb462d --- sources/gui/qml/components/ConfirmButton.qml (.../ConfirmButton.qml) (revision c0c63c4b149dafea2b02e4cd31f223e392ff7818) +++ sources/gui/qml/components/ConfirmButton.qml (.../ConfirmButton.qml) (revision 3229695c1c67de600c095d52c6f99dacfafb462d) @@ -32,7 +32,7 @@ anchors { top : parent.top - left : parent.left + right : parent.right margins : 35 } } Index: sources/gui/qml/components/EntryDialog.qml =================================================================== diff -u --- sources/gui/qml/components/EntryDialog.qml (revision 0) +++ sources/gui/qml/components/EntryDialog.qml (revision 3229695c1c67de600c095d52c6f99dacfafb462d) @@ -0,0 +1,113 @@ +/*! + * + * 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 EntryDialog.qml + * \author (last) Behrouz NematiPour + * \author (original) Behrouz NematiPour + * \date (last) 18-06-2021 + * \date (original) 18-06-2021 + * + */ + +// Qt +import QtQuick 2.12 + +// Qml imports +import "qrc:/globals" +import "qrc:/components" + +/*! + * \brief EntryDialog is a dialog like scree + * This screen has been disigned to be able to accept user inputs like TextEntry + * which requires Keyboard since the dialogs will cover the keyboard + */ +Rectangle { id: _root + objectName: "EntryDialog" //SquishQt testability + + default property alias content : _backgroundRect.data + + signal closeClicked() + signal confirmClicked() + + property bool closeVisible : true + property bool confirmVisible : true + + property bool autoHide : false + property int autoHideDuration : 1000 + property alias contentRect : _backgroundRect + property alias backgroundColor : _backgroundRect.color + property alias textColor : _notification.textColor + property alias border : _backgroundRect.border + property alias radius : _backgroundRect.radius + property alias notificationText : _notification.text + property alias notification : _notification + property alias titleText : _titleText.text + + function open () { opacity = 1 } + function close () { opacity = 0 } + + width : Variables.applicationWidth + height : Variables.applicationHeight + opacity : 0 + visible : opacity + anchors.centerIn: parent + + color : Colors.borderDialog + Behavior on opacity { PropertyAnimation{}} + onVisibleChanged: { + console.debug("Visible", visible) + notificationText = "" + } + + MouseArea { id: _modal + anchors.fill: parent + } + + Rectangle { id: _backgroundRect + anchors.centerIn: parent + width : Variables.dialogWidth + height : Variables.dialogHeight + color : Colors.backgroundDialog + radius : Variables.dialogRadius + Rectangle { id : _headerRect + anchors.top: parent.top + anchors.left: parent.left + anchors.right: parent.right + + ConfirmButton { id : _confirmButton + visible: _root.confirmVisible + onClicked : { + confirmClicked() + _keyboard.setVisible(false) + } + } + + TitleText { id : _titleText + font.pixelSize: Fonts.fontPixelButton + color: Colors.textMain + height: Variables.mainMenuHeight + anchors { + top: parent.top + horizontalCenter: parent.horizontalCenter + margins: 35 + } + } + + CloseButton { id : _closeButton + visible: _root.closeVisible + anchors.left: parent.left + onClicked : { + closeClicked() + _keyboard.setVisible(false) + close() + } + } + } + } + + NotificationBar { id: _notification } +} Index: sources/gui/qml/components/ModalDialog.qml =================================================================== diff -u -r45ce6e781782be5de1480a1e7acecd1d272bcc84 -r3229695c1c67de600c095d52c6f99dacfafb462d --- sources/gui/qml/components/ModalDialog.qml (.../ModalDialog.qml) (revision 45ce6e781782be5de1480a1e7acecd1d272bcc84) +++ sources/gui/qml/components/ModalDialog.qml (.../ModalDialog.qml) (revision 3229695c1c67de600c095d52c6f99dacfafb462d) @@ -29,11 +29,11 @@ property bool autoHide : false property int autoHideDuration : 1000 - property alias notificationText : _notification.text property alias backgroundColor : _backgroundRect.color property alias textColor : _notification.textColor property alias border : _backgroundRect.border property alias radius : _backgroundRect.radius + property alias notificationText : _notification.text property alias notification : _notification width : Variables.dialogWidth Index: sources/gui/qml/compounds/StepNavigationTitleBar.qml =================================================================== diff -u -r4afc91856c00e01dfb5d84bc54d2d92faefec0db -r3229695c1c67de600c095d52c6f99dacfafb462d --- sources/gui/qml/compounds/StepNavigationTitleBar.qml (.../StepNavigationTitleBar.qml) (revision 4afc91856c00e01dfb5d84bc54d2d92faefec0db) +++ sources/gui/qml/compounds/StepNavigationTitleBar.qml (.../StepNavigationTitleBar.qml) (revision 3229695c1c67de600c095d52c6f99dacfafb462d) @@ -55,11 +55,6 @@ objectName: "_confirmButton" visible: false enabled: true - anchors { - left : undefined - top : parent.top - right : parent.right - } onClicked: _root.confirmClicked() } Index: sources/gui/qml/dialogs/DiagnosticsDialog.qml =================================================================== diff -u -r7077e38c74db9cccb5496ffefcf8936c0916de76 -r3229695c1c67de600c095d52c6f99dacfafb462d --- sources/gui/qml/dialogs/DiagnosticsDialog.qml (.../DiagnosticsDialog.qml) (revision 7077e38c74db9cccb5496ffefcf8936c0916de76) +++ sources/gui/qml/dialogs/DiagnosticsDialog.qml (.../DiagnosticsDialog.qml) (revision 3229695c1c67de600c095d52c6f99dacfafb462d) @@ -50,6 +50,8 @@ radius : width } CloseButton { id : _closeButton + anchors.left : undefined + anchors.right : parent.right anchors.top : undefined anchors.bottom : parent.bottom anchors.margins : 10 Index: sources/gui/qml/main.qml =================================================================== diff -u -r13d6a4fae2f910ab6e289ac9280258a94f734405 -r3229695c1c67de600c095d52c6f99dacfafb462d --- sources/gui/qml/main.qml (.../main.qml) (revision 13d6a4fae2f910ab6e289ac9280258a94f734405) +++ sources/gui/qml/main.qml (.../main.qml) (revision 3229695c1c67de600c095d52c6f99dacfafb462d) @@ -259,7 +259,13 @@ } } + // keyboard should always be before AlarmItem to not to covet it. + Keyboard { id: _keyboard } + + // AlarmItem should always be at the end so nothing covers it AlarmItem { id: _alarmItem ; z: 998 } + + // this dialog as an exception can cover the Alarm for debugging and testing. DiagnosticsDialog { id: _diagnosticsDialog; z: 999 } // NotificationBar has to be anchored to the main menu and if it is moved into the AlarmItem @@ -274,5 +280,4 @@ backgroundFading : vHDOperationMode.fault } - Keyboard { id: _keyboard } } Index: sources/gui/qml/pages/settings/SettingsBase.qml =================================================================== diff -u -r56ad953ae404fcf6956bd4f76b7a54b12d0285d3 -r3229695c1c67de600c095d52c6f99dacfafb462d --- sources/gui/qml/pages/settings/SettingsBase.qml (.../SettingsBase.qml) (revision 56ad953ae404fcf6956bd4f76b7a54b12d0285d3) +++ sources/gui/qml/pages/settings/SettingsBase.qml (.../SettingsBase.qml) (revision 3229695c1c67de600c095d52c6f99dacfafb462d) @@ -74,11 +74,6 @@ objectName: "_confirmButton" visible: true enabled: true - anchors { - left : undefined - top : parent.top - right : parent.right - } onClicked: { _root.confirmClicked() _keyboard.setVisible(false) Index: sources/gui/qml/pages/treatment/TreatmentStack.qml =================================================================== diff -u -r506a9e3db1a20bda1685e38c5e9041005c9a4a4f -r3229695c1c67de600c095d52c6f99dacfafb462d --- sources/gui/qml/pages/treatment/TreatmentStack.qml (.../TreatmentStack.qml) (revision 506a9e3db1a20bda1685e38c5e9041005c9a4a4f) +++ sources/gui/qml/pages/treatment/TreatmentStack.qml (.../TreatmentStack.qml) (revision 3229695c1c67de600c095d52c6f99dacfafb462d) @@ -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 TreatmentStack.qml * \author (last) Behrouz NematiPour * \date (last) 28-Feb-2021 * \author (original) Behrouz NematiPour * \date (original) 27-Jan-2020 - * + * */ // Qt @@ -56,14 +56,63 @@ hasLogo : true } + EntryDialog { id: _vitalEntry + property int labelWidth : 200 + property int entryWidth : 100 + property int titleIndent : 25 + property int topMarginContent : 200 + + titleText: qsTr("VITALS") + Row { id: _container + spacing: 50 + y : Qt.inputMethod.visible && _keyboard.visible ? _vitalEntry.topMarginContent : ( (_vitalEntry.contentRect.height - _container.height) / 2 ) + Behavior on y { NumberAnimation { duration: Variables.keybardAnimationDuration } } + anchors.horizontalCenter: parent.horizontalCenter + + Column { + spacing : 25 + leftPadding : _vitalEntry.titleIndent + Row { + spacing : 10 + TextEntry { id : _bloodPressureSystolic + text : "‑‑" + label.text : qsTr("Blood Pressure") + label.width : _vitalEntry.labelWidth + validator : IntValidator { bottom: 0; top : 7 } // TODO: Settings Manufacturing + nextInput : _bloodPressureDiastolic + } + Label { + text : qsTr("/") + width : 10 + } + TextEntry { id : _bloodPressureDiastolic + text : "" + label.width : 0 + validator : IntValidator { bottom: 0; top : 7 } // TODO: Settings Manufacturing + nextInput : _heartRate + } + Label { + text: qsTr("mmHg") + } + } + TextEntry { id : _heartRate + text : "" + label.text : qsTr("Heart Rate") + label.width : _vitalEntry.labelWidth + validator : IntValidator { bottom: 0; top : 7 } // TODO: Settings Manufacturing + } + } + } + } + TreatmentBloodPrime { id: _treatmentBloodPrime } TreatmentUltrafiltrationItem{ id: _treatmentUltrafiltrationItem } TreatmentHome { id: _treatmentHome onSectionFlowClicked : { _treatmentAdjustmentFlow.open() } onSectionVitalsClicked : { - // no page yet + _vitalEntry.open() } onSectionPressuresClicked: { _treatmentAdjustmentPressuresLimits.open() @@ -79,18 +128,16 @@ //// Treatment Adjustment Dialogs TreatmentAdjustmentFlow { id: _treatmentAdjustmentFlow - onCloseClicked : close() onConfirmClicked : vTreatmentAdjustmentFlows.doAdjustment(bloodFlowRateValue, dialysateFlowRateValue) } TreatmentAdjustmentPressuresLimits { id: _treatmentAdjustmentPressuresLimits - onCloseClicked : close() onConfirmClicked : vTreatmentAdjustmentPressuresLimits.doAdjustment( arterialPressureLowerBound , arterialPressureUpperBound , venousPressureLowerBound , venousPressureUpperBound - ) + ) arterialPressureMinimum : Variables.arterialValueMin arterialPressureLowerBound : vTreatmentAdjustmentPressuresLimits.arterialLimitLow @@ -110,7 +157,6 @@ } TreatmentAdjustmentDuration { id: _treatmentAdjustmentDuration - onCloseClicked : close() onConfirmClicked : vTreatmentAdjustmentDuration.doAdjustment(durationValue) } Index: sources/gui/qml/pages/treatment/adjustments/TreatmentAdjustmentBase.qml =================================================================== diff -u -r2c9421bd6da03c7e0bd0bfa1f49fa95c2bd18a95 -r3229695c1c67de600c095d52c6f99dacfafb462d --- sources/gui/qml/pages/treatment/adjustments/TreatmentAdjustmentBase.qml (.../TreatmentAdjustmentBase.qml) (revision 2c9421bd6da03c7e0bd0bfa1f49fa95c2bd18a95) +++ sources/gui/qml/pages/treatment/adjustments/TreatmentAdjustmentBase.qml (.../TreatmentAdjustmentBase.qml) (revision 3229695c1c67de600c095d52c6f99dacfafb462d) @@ -50,12 +50,10 @@ Rectangle { id : _headerRect ConfirmButton { id : _confirmButton visible: _root.confirmVisible - anchors.left: parent.left onClicked : confirmClicked() } BackButton { id : _backButton visible: _root.backVisible - anchors.left: parent.left onClicked : backClicked() } @@ -73,8 +71,11 @@ CloseButton { id : _closeButton visible: _root.closeVisible - anchors.right: parent.right - onClicked : closeClicked() + anchors.left: parent.left + onClicked : { + closeClicked() + close() + } } } Index: sources/gui/qml/pages/treatment/sections/TreatmentVitals.qml =================================================================== diff -u -r56e378f7504701b9e9a9dccaf205aef2fd52c58e -r3229695c1c67de600c095d52c6f99dacfafb462d --- sources/gui/qml/pages/treatment/sections/TreatmentVitals.qml (.../TreatmentVitals.qml) (revision 56e378f7504701b9e9a9dccaf205aef2fd52c58e) +++ sources/gui/qml/pages/treatment/sections/TreatmentVitals.qml (.../TreatmentVitals.qml) (revision 3229695c1c67de600c095d52c6f99dacfafb462d) @@ -29,9 +29,12 @@ property alias textRectBloodPressure : _bloodPressure property alias textRectHeartBeat : _heartBeat + property int bpSystolic : 0 + property int bpDiastolic: 0 + property int heartRate : 0 + x: 0 y: 0 - isTouchable: false title: qsTr("VITALS") Column { @@ -42,15 +45,15 @@ labelFont.pixelSize: Fonts.fontPixelVitals labelFont.weight: Font.ExtraLight labelAutoSize: true - label: "120/80" // value + label: (bpSystolic ? bpSystolic : "‑‑‑") + " / " + (bpDiastolic ? bpDiastolic : "‑‑") extra: Variables.unitTextBloodPressure } TextRect { id: _heartBeat labelHeight: 40 labelFont.pixelSize: Fonts.fontPixelVitals labelFont.weight: Font.ExtraLight labelAutoSize: true - label: "130" // value + label: heartRate ? heartRate : "‑‑" extra: Variables.unitTextHeartBeat } } Index: sources/view/hd/alarm/VAlarmStatus.h =================================================================== diff -u -r7a1509a80fed2dd51aa28b460acbf0227d0c96d7 -r3229695c1c67de600c095d52c6f99dacfafb462d --- sources/view/hd/alarm/VAlarmStatus.h (.../VAlarmStatus.h) (revision 7a1509a80fed2dd51aa28b460acbf0227d0c96d7) +++ sources/view/hd/alarm/VAlarmStatus.h (.../VAlarmStatus.h) (revision 3229695c1c67de600c095d52c6f99dacfafb462d) @@ -65,7 +65,7 @@ PROPERTY( bool , alarm_Flag_alarmsToEscalate , false) PROPERTY( bool , alarm_Flag_alarmsSilenced , false) PROPERTY( bool , alarm_Flag_alarmsLampOn , false) - // 3 reserved flags are here... + // 3 reserved flags are here... // PROPERTY( bool , alarm_Flag_noMinimize , false) PROPERTY( bool , alarm_Flag_alarmsCondition , false) // coco end