File tree Expand file tree Collapse file tree 1 file changed +35
-13
lines changed
meshroom/ui/qml/GraphEditor Expand file tree Collapse file tree 1 file changed +35
-13
lines changed Original file line number Diff line number Diff line change @@ -377,19 +377,41 @@ Item {
377377 }
378378
379379 // Node Chunks
380- NodeChunks {
381- visible: node .isComputable
382- defaultColor: Colors .sysPalette .mid
383- implicitHeight: 3
384- width: parent .width
385- model: node ? node .chunks : undefined
386-
387- Rectangle {
388- anchors .fill : parent
389- color: Colors .sysPalette .mid
390- z: - 1
391- }
392- }
380+ Column {
381+ width: parent .width
382+
383+ spacing: 2
384+ Repeater {
385+ // the model is the number of iterations for the for loop
386+ // so if the count is 0 we display only one iteration
387+ // else we display the number of iterations
388+ model: {
389+ if (node .countForLoop === 0 )
390+ return 1
391+
392+ for (let i = 0 ; i < node .attributes .count ; ++ i) {
393+ if (node .attributes .at (i).isLink ) {
394+ var srcAttr = node .attributes .at (i).linkParam
395+ return srcAttr .root .value .count
396+ }
397+ }
398+ }
399+
400+ delegate: NodeChunks {
401+ visible: node .isComputable
402+ defaultColor: Colors .sysPalette .mid
403+ height: 3
404+ width: parent .width
405+ model: node ? node .chunks : undefined
406+
407+ Rectangle {
408+ anchors .fill : parent
409+ color: Colors .sysPalette .mid
410+ z: - 1
411+ }
412+ }
413+ }
414+ }
393415
394416 // Vertical Spacer
395417 Item { width: parent .width ; height: 2 }
You can’t perform that action at this time.
0 commit comments