(numChildren, nestingLevel)
| 106 | |
| 107 | |
| 108 | def addChild(numChildren, nestingLevel): |
| 109 | result = [] |
| 110 | |
| 111 | if nestingLevel == 0: |
| 112 | return result |
| 113 | |
| 114 | for i in range(numChildren): |
| 115 | child = QStandardItem( |
| 116 | "Child num {}, nesting level {}".format(i + 1, nestingLevel)) |
| 117 | |
| 118 | if i == 0: |
| 119 | child.appendRow(addChild(numChildren, nestingLevel - 1)) |
| 120 | |
| 121 | result.append(child) |
| 122 | |
| 123 | return result |
| 124 | |
| 125 | |
| 126 | if __name__ == '__main__': |
no test coverage detected