209-fit-tree #222
@ -70,7 +70,7 @@ class FitModelTree(QtWidgets.QTreeWidget):
|
||||
self.remove_function(item)
|
||||
|
||||
elif evt.key() == QtCore.Qt.Key.Key_Space:
|
||||
for item in self.treeWidget.selectedItems():
|
||||
for item in self.selectedItems():
|
||||
cs = item.checkState(0)
|
||||
if cs == QtCore.Qt.CheckState.Unchecked:
|
||||
item.setCheckState(0, QtCore.Qt.CheckState.Checked)
|
||||
|
@ -26,8 +26,13 @@ class ModelFactory:
|
||||
if func['children']:
|
||||
right, _, _ = ModelFactory.create_from_list(func['children'], left_cnt=func['pos'],
|
||||
func_order=func_order, param_len=param_len)
|
||||
right_cnt = None
|
||||
right = MultiModel(func['func'], right, func['children'][0]['op'], left_idx=func['cnt'], right_idx=None)
|
||||
|
||||
if right is None:
|
||||
right = func['func']
|
||||
right_cnt = func['cnt']
|
||||
else:
|
||||
right_cnt = None
|
||||
right = MultiModel(func['func'], right, func['children'][0]['op'], left_idx=func['cnt'], right_idx=None)
|
||||
else:
|
||||
right = func['func']
|
||||
right_cnt = func['cnt']
|
||||
|
Loading…
Reference in New Issue
Block a user