Index: sources/gui/qml/pages/posttreatment/PostTreatmentReview.qml =================================================================== diff -u -reaf21ffe52c818b4c8abdb2084582ada9dc78ceb -r5687815256ae070a9a207107088e3f72dd464da0 --- sources/gui/qml/pages/posttreatment/PostTreatmentReview.qml (.../PostTreatmentReview.qml) (revision eaf21ffe52c818b4c8abdb2084582ada9dc78ceb) +++ sources/gui/qml/pages/posttreatment/PostTreatmentReview.qml (.../PostTreatmentReview.qml) (revision 5687815256ae070a9a207107088e3f72dd464da0) @@ -1,13 +1,13 @@ /*! * - * Copyright (c) 2021-2022 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 PostTreatmentReview.qml * \author (last) Behrouz NematiPour - * \date (last) 03-Mar-2022 + * \date (last) 31-Jul-2024 * \author (original) Behrouz NematiPour * \date (original) 21-Apr-2021 * @@ -36,19 +36,58 @@ header.confirmText.text: qsTr("NEXT") - ExportButton { + ExportButton { id: _exportButton + isSmall : true anchors.top : parent.top anchors.left : parent.left - exportFunction : vPostTreatmentAdjustmentTreatmentLog.doExport - enabled : vPostTreatmentAdjustmentTreatmentLog.isIdle && _GuiView.usbReady + enabled : vPostTreatmentAdjustmentTreatmentLog.isIdle && _GuiView.usbIsReady && !_GuiView.exportRunning + onClicked : vPostTreatmentAdjustmentTreatmentLog.doExport() } + USBButton { id: _usbButton + anchors.top : _exportButton.top + anchors.left : _exportButton.right + anchors.leftMargin: Variables.minVGap + enabled : _GuiView.usbIsReady && !_GuiView.exportRunning + } ScrollBar { anchors.fill: _flickable flickable : _flickable backColor : Colors.backgroundDialog } + Label { id: _txCode + property string empty : "..." + property string txCode : vPostTreatmentAdjustmentTreatmentLog.txCode + Timer { id: _waitTxCodeTimer + property int count: 0 + interval: 1000 + repeat : true + running : _txCode.visible && ! _txCode.txCode + onTriggered: { + _txCode.empty = ".".repeat( count ++ ) + if ( count == 4 ) count = 0 + } + } + + anchors.bottom : _flickable.top + anchors.left : _flickable.left + width : _flickable.width + text : qsTr("Code: ") + ( txCode ? txCode : empty ) + 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 : vPostTreatmentAdjustmentTreatmentLog.txCode + clear : ! _root.visible + } + Flickable { id: _flickable clip: true anchors { @@ -96,6 +135,7 @@ onItemClicked: _root.itemClicked(vIndex) } } - reasonText: vPostTreatmentAdjustmentTreatmentLog.text() + reasonText : vPostTreatmentAdjustmentTreatmentLog.text() + informationText : vPostTreatmentAdjustmentTreatmentLog.notification }