@@ -15,6 +15,7 @@ Panel {
1515 id: root
1616
1717 property variant node
18+ property string globalStatus : node .globalStatus
1819 property bool readOnly: false
1920 property bool isCompatibilityNode: node && node .compatibilityIssue !== undefined
2021 property string nodeStartDateTime: " "
@@ -25,16 +26,19 @@ Panel {
2526 title: " Node" + (node !== null ? " - <b>" + node .label + " </b>" + (node .label !== node .defaultLabel ? " (" + node .defaultLabel + " )" : " " ) : " " )
2627 icon: MaterialLabel { text: MaterialIcons .tune }
2728
28- onNodeChanged : {
29+ onGlobalStatusChanged : {
2930 nodeStartDateTime = " "
3031 if (node !== null && node .isRunning ()) {
3132 timer .start ()
3233 }
33- else if (node !== null && (node .isFinishedOrRunning () || node .globalStatus == " ERROR" )) {
34- computationInfo .text = Format .getTimeStr (node .elapsedTime )
35- }
3634 else {
37- computationInfo .text = " "
35+ timer .stop ()
36+ if (node !== null && (node .isFinishedOrRunning () || globalStatus== " ERROR" )) {
37+ computationInfo .text = Format .getTimeStr (node .elapsedTime )
38+ }
39+ else {
40+ computationInfo .text = " "
41+ }
3842 }
3943 }
4044
@@ -50,22 +54,9 @@ Panel {
5054 onTriggered: {
5155 if (nodeStartDateTime === " " ) {
5256 nodeStartDateTime = new Date (node .getStartDateTime ()).getTime ()
53- }
54- var now = new Date ().getTime ()
55- var runningTime= Format .getTimeStr ((now- nodeStartDateTime)/ 1000 )
56-
57- var chunksCompleted = 0
58- var chunkCompletion = " "
59- if (node .chunks .count > 0 ) {
60- for (var i = 0 ; i < node .chunks .count ; i++ ) {
61- if (node .chunks .at (i).statusName == " SUCCESS" ) {
62- chunksCompleted++
63- }
64- }
65- chunkCompletion = " | " + chunksCompleted + " /" + node .chunks .count + " chunk" + (node .chunks .count == 1 ? " " : " s" )
6657 }
67- parent . text = runningTime + chunkCompletion
68-
58+ var now = new Date (). getTime ()
59+ parent . text = Format . getTimeStr ((now - nodeStartDateTime) / 1000 )
6960 }
7061 }
7162 padding: 2
0 commit comments