Index: sources/gui/qml/pages/pretreatment/create/PreTreatmentConfirm.qml =================================================================== diff -u -r43b80bc100e5bbc5f940e014cb622b5269a55e6c -r5687815256ae070a9a207107088e3f72dd464da0 --- sources/gui/qml/pages/pretreatment/create/PreTreatmentConfirm.qml (.../PreTreatmentConfirm.qml) (revision 43b80bc100e5bbc5f940e014cb622b5269a55e6c) +++ sources/gui/qml/pages/pretreatment/create/PreTreatmentConfirm.qml (.../PreTreatmentConfirm.qml) (revision 5687815256ae070a9a207107088e3f72dd464da0) @@ -1,15 +1,15 @@ /*! * - * Copyright (c) 2019-2020 Diality Inc. - All Rights Reserved. + * Copyright (c) 2021-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 PreTreatmentConfirm.qml * \author (last) Behrouz NematiPour - * \date (last) 12-Jan-2021 - * \author (original) Peter Lucia - * \date (original) 03-Aug-2020 + * \date (last) 31-Jul-2024 + * \author (original) Behrouz NematiPour + * \date (original) 12-Jan-2021 * */ @@ -21,6 +21,8 @@ // Qml imports import "qrc:/globals" import "qrc:/components" +import "qrc:/compounds" +import "qrc:/pages/pretreatment" /*! * \brief Pre-Treatment confirm screen @@ -29,60 +31,73 @@ PreTreatmentBase { id: _root objectName: "_PreTreatmentConfirm" - signal confirmClicked() + // removed for now, since after removing the A/V Min/Max, scrolling is not needed + // ScrollBar { + // backColor : Colors.backgroundDialog + // flickable : _flickable + // anchors.fill: _flickable + // anchors.rightMargin : Variables.minVGap2 + // anchors.leftMargin : Variables.minVGap2 + // } - header.stepName: Variables.preTreatmentStepLabelConfirm + Label { id: _txCode + anchors.bottom : _flickable.top + anchors.left : _flickable.left + width : _flickable.width + text : qsTr("Code: ") + vTreatmentCreate.txCode + font.pixelSize : Fonts.fontPixelButton + } + QRCode { id: _qrCode + // removed for the P1 release, since the code had a big change and cannot be removed entirely + // added for the P1B release + visible : true + anchors.bottom : _flickable.top + anchors.right : _flickable.right + anchors.margins : 15 + qrcode : vTreatmentCreate.txCode + clear : ! _root.visible + } + Flickable { id: _flickable objectName: "_PreTreatmentConfirmFlickable" + interactive: false + Background { // Used instead of ScrollBar background + color : Colors.backgroundDialog + // anchors.rightMargin : Variables.minVGap2 + // anchors.leftMargin : Variables.minVGap2 + } + clip: true anchors { - top : parent.top - topMargin : header.height - bottom : parent.bottom - bottomMargin : 75 + top : _root.title.bottom + topMargin : Variables.minVGap * 2 // * 2 : it was too close to title and also better with rows not half cut. + bottom : _root.bottom + bottomMargin : Variables.notificationHeight + Variables.minVGap horizontalCenter: parent.horizontalCenter } - width: parent.width - contentWidth: parent.width - contentHeight: _column.implicitHeight - clip: true + width : parent.width - Variables.minVGap2 * 2 // * 2 : for each side + contentWidth : width + contentHeight: height - ScrollBar.vertical: ScrollBar { id: _scrollBar - anchors.right: _flickable.right - anchors.rightMargin: 3 - contentItem: Rectangle { - color: Colors.backgroundRangeRect - implicitWidth: 6 - radius: width / 2 - width: 3 - } - } - + // TODO: remove this and the sub components and use the TouchGrid instead like in the PostTreatmentReview.qml Column { id: _column - spacing: Variables.treatmentSpacing anchors.horizontalCenter: parent.horizontalCenter; anchors.fill: parent; - - Text { id: _titleText - anchors.horizontalCenter: parent.horizontalCenter; - text: qsTr("Confirm Treatment") - color: Colors.textMain - font.pixelSize: Fonts.fontPixelTitle - } // insert the treatment information table here ConfirmTreatmentTable { anchors.horizontalCenter: parent.horizontalCenter - } - - TouchRect { id : _continueRect - objectName: "_continueRect" - anchors.horizontalCenter: parent.horizontalCenter - text.text: qsTr("CONFIRM TREATMENT") - button.onClicked: { - _root.confirmClicked() - } - } } + + // removed for now, since after removing the A/V Min/Max, scrolling is not needed + // onAtYEndChanged: { + // if (_flickable.atYEnd) header.confirmEnabled = true + // } } + + // removed fro now, since after removing the A/V Min/Max, scrolling is not needed + // onVisibleChanged: { + // _flickable.contentY = 0 // scroll back to top + // header.confirmEnabled = false + // } }